Commit 4cd72b53 authored by Michael Meskes's avatar Michael Meskes

Added missing ECPGget_sqlca() call

parent c1c9b7c0
/* $PostgreSQL: pgsql/src/interfaces/ecpg/ecpglib/misc.c,v 1.28 2006/07/31 10:15:30 meskes Exp $ */
/* $PostgreSQL: pgsql/src/interfaces/ecpg/ecpglib/misc.c,v 1.29 2006/07/31 13:26:46 meskes Exp $ */
#define POSTGRES_ECPG_INTERNAL
#include "postgres_fe.h"
......@@ -239,6 +239,7 @@ void
ECPGlog(const char *format,...)
{
va_list ap;
struct sqlca_t *sqlca = ECPGget_sqlca();
#ifdef ENABLE_THREAD_SAFETY
pthread_mutex_lock(&debug_mutex);
......@@ -273,7 +274,7 @@ ECPGlog(const char *format,...)
/* dump out internal sqlca variables */
if (getenv("ECPG_DONT_LOG_PID"))
fprintf(debugstream, "[NO_PID]: sqlca: code: %ld, state: %s\n",
sqlca.sqlcode, sqlca.sqlstate);
sqlca->sqlcode, sqlca->sqlstate);
fflush(debugstream);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment