From: Alan T. DeKok Date: Sun, 22 Nov 2009 08:12:15 +0000 (+0100) Subject: Revert "errormsg may be NULL" X-Git-Tag: release_2_1_8~71 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=37e71f4896366598bb2a614755e9b7ecb2b54158;p=thirdparty%2Ffreeradius-server.git Revert "errormsg may be NULL" This reverts commit 45877bf44b02d418b6fb263a39e5de07ced58b6e. It doesn't fix the problem, and it seems to cause issues for other people --- diff --git a/src/modules/rlm_sql/drivers/rlm_sql_postgresql/sql_postgresql.c b/src/modules/rlm_sql/drivers/rlm_sql_postgresql/sql_postgresql.c index 22c045fb65e..21f4850adb4 100644 --- a/src/modules/rlm_sql/drivers/rlm_sql_postgresql/sql_postgresql.c +++ b/src/modules/rlm_sql/drivers/rlm_sql_postgresql/sql_postgresql.c @@ -275,9 +275,6 @@ static int sql_query(SQLSOCK * sqlsocket, SQL_CONFIG *config, char *querystr) { errorcode = PQresultErrorField(pg_sock->result, PG_DIAG_SQLSTATE); errormsg = PQresultErrorField(pg_sock->result, PG_DIAG_MESSAGE_PRIMARY); - - if (!errormsg) errormsg = "FATAL ERROR"; - radlog(L_DBG, "rlm_sql_postgresql: Error %s", errormsg); return check_fatal_error(errorcode); #endif