summaryrefslogtreecommitdiffabout
path: root/src/mysql.c
Side-by-side diff
Diffstat (limited to 'src/mysql.c') (more/less context) (ignore whitespace changes)
-rw-r--r--src/mysql.c19
1 files changed, 6 insertions, 13 deletions
diff --git a/src/mysql.c b/src/mysql.c
index 1310212..dcc1847 100644
--- a/src/mysql.c
+++ b/src/mysql.c
@@ -21,24 +21,17 @@
#include <guile-sql.h>
#include <mysql/mysql.h>
-static SCM
-s_mysql_mark(struct sql_connect *conn)
-{
- return SCM_BOOL_F;
-}
-
-static scm_sizet
+static size_t
s_mysql_free(struct sql_connect *conn)
{
MYSQL *mysql = (MYSQL*) conn->data;
- if (!mysql)
- return 0;
- mysql_close(mysql);
- return sizeof(MYSQL);
+ if (mysql)
+ mysql_close(mysql);
+ return 0;
}
static SCM
-s_mysql_connect (SCM parmlist, const char *func_name)
+s_mysql_connect(SCM parmlist, const char *func_name)
{
char *hostname = NULL;
int port = 0;
@@ -225,7 +218,7 @@ s_mysql_close(struct sql_connect *conn)
struct sql_iface mysql_iface = {
"mysql",
- s_mysql_mark,
+ NULL, /* mark */
s_mysql_free,
s_mysql_connect,
s_mysql_close,

Return to:

Send suggestions and report system problems to the System administrator.