Re: cvs: php-src(PHP_5_3) /ext/pdo pdo_dbh.c

From: Date: Tue, 04 Nov 2008 19:09:18 +0000
Subject: Re: cvs: php-src(PHP_5_3) /ext/pdo pdo_dbh.c
References: 1  Groups: php.cvs php.doc 
Request: Send a blank email to phpdoc+get-969379619@lists.php.net to get a copy of this message
On Tue, 2008-11-04 at 18:28 +0000, "David Coallier" wrote: > @@ -1004,6 +1009,8 @@ > add_next_index_string(return_value, dbh->query_stmt->error_code, 1); > } else { > add_next_index_string(return_value, dbh->error_code, 1); > + add_next_index_null(return_value); > + add_next_index_null(return_value); > } > if (dbh->methods->fetch_err) { > dbh->methods->fetch_err(dbh, dbh->query_stmt, return_value TSRMLS_CC); The error handler's fetch_err will most likely do a add_next_index_* call too, that will give you 5 elements. *if* you really want to fix that you should check the array size after calling the driver's fetch_error and add missing elements, while I don't know if it's really worth the trouble... johannes p.s. we need a stricter PDO spec :-(

« previous php.doc (#969379619) next »