summaryrefslogtreecommitdiff
path: root/ext/mssql/php_mssql.c
diff options
context:
space:
mode:
authorIlia Alshanetsky <iliaa@php.net>2008-02-10 14:49:23 +0000
committerIlia Alshanetsky <iliaa@php.net>2008-02-10 14:49:23 +0000
commita28b1f6d3abf3f2db1cb2c54ba750b94fb6e08c8 (patch)
treec231a40eb671f60c614eb3b682c7a60b86cb2cd3 /ext/mssql/php_mssql.c
parent824b19a4d82648399d594f33127b2910fd09e811 (diff)
downloadphp-git-a28b1f6d3abf3f2db1cb2c54ba750b94fb6e08c8.tar.gz
Possible fix for bug #43861
Diffstat (limited to 'ext/mssql/php_mssql.c')
-rw-r--r--ext/mssql/php_mssql.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/ext/mssql/php_mssql.c b/ext/mssql/php_mssql.c
index 986c2520e5..7987046982 100644
--- a/ext/mssql/php_mssql.c
+++ b/ext/mssql/php_mssql.c
@@ -890,6 +890,10 @@ static void php_mssql_get_column_content_with_type(mssql_link *mssql_ptr,int off
DBDATEREC dateinfo;
int res_length = dbdatlen(mssql_ptr->link,offset);
+ if (res_length == -1) {
+ res_length = 255;
+ }
+
if ((column_type != SQLDATETIME && column_type != SQLDATETIM4) || MS_SQL_G(datetimeconvert)) {
switch (column_type) {