From: Antony Dovgal Date: Fri, 28 Oct 2005 15:01:47 +0000 (+0000) Subject: fix #35003 (Warning: PDOStatement::fetch(): column 0 data was too large for buffer... X-Git-Tag: RELEASE_2_0_1~133 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=04ebdfa967d02b49fc15944ed0797a2254aa6001;p=php fix #35003 (Warning: PDOStatement::fetch(): column 0 data was too large for buffer and was) this is just a quick fix, the real one will follow after the weekend from Wez --- diff --git a/ext/pdo_oci/oci_statement.c b/ext/pdo_oci/oci_statement.c index 10a4d2f325..3b93cbfb27 100755 --- a/ext/pdo_oci/oci_statement.c +++ b/ext/pdo_oci/oci_statement.c @@ -395,6 +395,19 @@ static int oci_stmt_describe(pdo_stmt_t *stmt, int colno TSRMLS_DC) /* {{{ */ /* how much room do we need to store the field */ switch (dtype) { + case SQLT_LBI: + case SQLT_LNG: + dyn = FALSE; + if (dtype == SQLT_LBI) { + dtype = SQLT_BIN; + } else { + dtype = SQLT_CHR; + } + S->cols[colno].datalen = 512; /* XXX should be INT_MAX and fetched by pieces */ + S->cols[colno].data = emalloc(S->cols[colno].datalen + 1); + col->param_type = PDO_PARAM_STR; + break; + case SQLT_BIN: default: dyn = FALSE;