From: Zeev Suraski Date: Mon, 15 Jan 2001 10:22:19 +0000 (+0000) Subject: Fix Win32 build X-Git-Tag: php-4.0.5RC1~566 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=90c8e2cf751038b0b8970ba9ea0ec201e3ae4cf6;p=php Fix Win32 build --- diff --git a/ext/odbc/php_odbc.c b/ext/odbc/php_odbc.c index ea0dfdb7d2..521a3b4e75 100644 --- a/ext/odbc/php_odbc.c +++ b/ext/odbc/php_odbc.c @@ -2418,7 +2418,7 @@ static void php_odbc_lasterror(INTERNAL_FUNCTION_PARAMETERS, int mode) { odbc_connection *conn; pval **pv_handle; - char *ptr, *dest; + char *ptr; int argc, len; argc = ZEND_NUM_ARGS(); @@ -2441,6 +2441,8 @@ static void php_odbc_lasterror(INTERNAL_FUNCTION_PARAMETERS, int mode) strncpy(ptr, conn->lasterrormsg, len); } } else { + ODBCLS_FETCH(); + if (mode == 0) { strncpy(ptr, ODBCG(laststate), len); } else {