Add new wrappers

This commit is contained in:
Joris Vink 2014-04-01 21:44:22 +02:00
parent 9e3d19fbbd
commit 39a9f7d6f0
1 changed files with 9 additions and 8 deletions

View File

@ -19,14 +19,6 @@
#include <libpq-fe.h>
void kore_pgsql_init(void);
void kore_pgsql_handle(void *, int);
void kore_pgsql_cleanup(struct http_request *);
void kore_pgsql_continue(struct http_request *, int);
int kore_pgsql_query(struct http_request *, char *, int);
int kore_pgsql_ntuples(struct http_request *, int);
struct kore_pgsql {
u_int8_t state;
char *error;
@ -34,6 +26,15 @@ struct kore_pgsql {
void *conn;
};
void kore_pgsql_init(void);
void kore_pgsql_handle(void *, int);
void kore_pgsql_cleanup(struct http_request *);
void kore_pgsql_continue(struct http_request *, int);
int kore_pgsql_query(struct http_request *, char *, int);
int kore_pgsql_ntuples(struct kore_pgsql *);
char *kore_pgsql_getvalue(struct kore_pgsql *, int, int);
#define KORE_PGSQL_STATE_INIT 1
#define KORE_PGSQL_STATE_WAIT 2
#define KORE_PGSQL_STATE_RESULT 3