summaryrefslogtreecommitdiffstats
path: root/dev-lang/php/files/php547-ds-odbc_blob.patch
blob: 041ce8460965661e9d27bf269ad7f24e28334519 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
diff -dPNur php-5.3.2/ext/pdo_odbc/odbc_stmt.c php-5.3.2-ds/ext/pdo_odbc/odbc_stmt.c
--- php-5.3.2/ext/pdo_odbc/odbc_stmt.c	2010-01-03 10:23:27.000000000 +0100
+++ php-5.3.2-ds/ext/pdo_odbc/odbc_stmt.c	2010-08-08 01:00:46.000000000 +0200
@@ -569,9 +569,15 @@
 			return 0;
 		}
 	}
+
+	if (displaysize < 0) {
+	    col->maxlen = S->cols[colno].datalen = 0;
+	    colsize = 256;
+	} else {
 	colsize = displaysize;
 
 	col->maxlen = S->cols[colno].datalen = colsize;
+	}
 	col->namelen = colnamelen;
 	col->name = estrdup(S->cols[colno].colname);
 	S->cols[colno].is_unicode = pdo_odbc_sqltype_is_unicode(S, S->cols[colno].coltype);