aboutsummaryrefslogtreecommitdiff
path: root/src/sql.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/sql.c')
-rw-r--r--src/sql.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/src/sql.c b/src/sql.c
index 1142b17..be21a2c 100644
--- a/src/sql.c
+++ b/src/sql.c
@@ -100,7 +100,7 @@ sql_free_result (struct access_method *method, void *handle)
}
return 0;
}
-
+
/* Finish the initialized MySQL access method */
int
sql_done_method (struct access_method *method)
@@ -116,7 +116,7 @@ sql_done_method (struct access_method *method)
return 0;
}
-/* Execute QUERY using the given access METHOD. Return 0 on success. */
+/* Execute QUERY using the given access METHOD. Return 0 on success. */
int
sql_run_method (struct access_method *method, void *handle, const char *query)
{
@@ -128,14 +128,14 @@ sql_run_method (struct access_method *method, void *handle, const char *query)
logmsg (LOG_ERR, "No query supplied for method %s", "sql");
return 1;
}
-
+
if (mysql_query (mysql, query))
{
logmsg (LOG_ERR, "Query failed: %s", mysql_error (mysql));
logmsg (LOG_NOTICE, "The failed query was: %s", query);
return 1;
}
-
+
conn->result = mysql_store_result (mysql);
if (!conn->result)
{
@@ -155,7 +155,7 @@ sql_run_method (struct access_method *method, void *handle, const char *query)
return 0;
}
-
+
int
sql_get_method (struct access_method *method, void *handle,
unsigned nrow, unsigned ncol)
@@ -176,7 +176,7 @@ sql_get_method (struct access_method *method, void *handle,
method_copy_result (method, row[ncol], len);
return 0;
}
-
+
int
sql_quote (struct access_method *method, void *handle, const char *input,
char **poutput, size_t *psize)
@@ -184,7 +184,7 @@ sql_quote (struct access_method *method, void *handle, const char *input,
struct sqlconn *conn = handle;
size_t len, size;
char *output;
-
+
len = strlen (input);
size = 2 * len + 1;
output = xmalloc (size);

Return to:

Send suggestions and report system problems to the System administrator.