summaryrefslogtreecommitdiffabout
path: root/src/pgsql.c
authorSergey Poznyakoff <gray@gnu.org.ua>2010-03-15 20:13:14 (GMT)
committer Sergey Poznyakoff <gray@gnu.org.ua>2010-03-15 20:13:14 (GMT)
commit5c3643f95a9d5568b64875ddf96a7e007050de72 (patch) (side-by-side diff)
treeef0b514e194dfdc4257040b8f2554df8f081895e /src/pgsql.c
parent7c6a94930dae634efd8af6db16578d8317153a9a (diff)
downloadgamma-5c3643f95a9d5568b64875ddf96a7e007050de72.tar.gz
gamma-5c3643f95a9d5568b64875ddf96a7e007050de72.tar.bz2
Use scm_from_locale_string instead of scm_makfrom0str.
Diffstat (limited to 'src/pgsql.c') (more/less context) (ignore whitespace changes)
-rw-r--r--src/pgsql.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/pgsql.c b/src/pgsql.c
index 759795e..7fceacd 100644
--- a/src/pgsql.c
+++ b/src/pgsql.c
@@ -71,8 +71,8 @@ s_pgsql_connect (SCM parmlist, const char *func_name)
free(user);
free(pass);
- pmsg = scm_makfrom0str(PQerrorMessage(pgconn));
- args = scm_list_1(scm_makfrom0str("Cannot connect to the database"));
+ pmsg = scm_from_locale_string(PQerrorMessage(pgconn));
+ args = scm_list_1(scm_from_locale_string("Cannot connect to the database"));
PQfinish(pgconn);
scm_error(gamma_sql_error, func_name,
"~A",
@@ -104,7 +104,7 @@ result_to_list(PGresult *res)
for (j = 0; j < nfields; j++) {
char *val = PQgetvalue(res, i, j);
- SCM new_elt = scm_cons(scm_makfrom0str(val), SCM_EOL);
+ SCM new_elt = scm_cons(scm_from_locale_string(val), SCM_EOL);
if (head == SCM_EOL)
head = new_elt;
else
@@ -135,9 +135,9 @@ s_pgsql_query(struct sql_connect *conn, const char *query)
if (!res)
scm_error(gamma_sql_error, "sql-query",
"~A",
- scm_list_1(scm_makfrom0str("Error executing PostgreSQL query")),
+ scm_list_1(scm_from_locale_string("Error executing PostgreSQL query")),
scm_list_2(SCM_BOOL_F,
- scm_makfrom0str(PQerrorMessage(pgconn))));
+ scm_from_locale_string(PQerrorMessage(pgconn))));
stat = PQresultStatus(res);
@@ -154,7 +154,7 @@ s_pgsql_query(struct sql_connect *conn, const char *query)
default:
scm_error(gamma_sql_error, "sql-query",
"~A",
- scm_list_1(scm_makfrom0str("PostgreSQL error")),
+ scm_list_1(scm_from_locale_string("PostgreSQL error")),
scm_list_2(scm_from_uint(stat),
scm_from_locale_string(PQresStatus(stat))));
}

Return to:

Send suggestions and report system problems to the System administrator.