com php-src: fixed fix #69975 wrt. ODBCVER < 0x0300: ext/odbc/php_odbc.c
| From: | Christoph Michael Becker | Date: | Fri, 03 Jul 2015 11:30:39 +0000 |
| Subject: | com php-src: fixed fix #69975 wrt. ODBCVER < 0x0300: ext/odbc/php_odbc.c | ||
| Groups: | php.cvs | ||
| Request: | Send a blank email to php-cvs+get-87730@lists.php.net to get a copy of this message | ||
Commit: 344ff5dd4c538eaebea075f7705321f8b86d0b47
Author: Christoph M. Becker <cmb@php.net> Fri, 3 Jul 2015 13:30:39 +0200
Parents: d870683d6b37884bd4baf9a3aa5cd3e43a3c432a
Branches: PHP-5.6 master
Link: http://git.php.net/?p=php-src.git;a=commitdiff;h=344ff5dd4c538eaebea075f7705321f8b86d0b47
Log:
fixed fix #69975 wrt. ODBCVER < 0x0300
Bugs:
https://bugs.php.net/69975
Changed paths:
M ext/odbc/php_odbc.c
Diff:
diff --git a/ext/odbc/php_odbc.c b/ext/odbc/php_odbc.c
index 80af492..1d70b7f 100644
--- a/ext/odbc/php_odbc.c
+++ b/ext/odbc/php_odbc.c
@@ -1007,14 +1007,14 @@ int odbc_bindcols(odbc_result *result TSRMLS_DC)
rc = SQLColAttributes(result->stmt, (SQLUSMALLINT)(i+1), SQL_COLUMN_DISPLAY_SIZE,
NULL, 0, NULL, &displaysize);
}
-#endif
+
/* Workaround for drivers that report NVARCHAR(MAX) columns as SQL_WVARCHAR with size 0 (bug
#69975) */
if (result->values[i].coltype == SQL_WVARCHAR && displaysize == 0) {
result->values[i].coltype = SQL_WLONGVARCHAR;
result->values[i].value = NULL;
break;
}
-
+#endif
/* Workaround for Oracle ODBC Driver bug (#50162) when fetching TIMESTAMP column */
if (result->values[i].coltype == SQL_TIMESTAMP) {
displaysize += 3;