]> granicus.if.org Git - php/commitdiff
Fixed bug #44166 (Parameter handling flaw in PDO::getAvailableDrivers())
authorIlia Alshanetsky <iliaa@php.net>
Mon, 3 Mar 2008 21:12:16 +0000 (21:12 +0000)
committerIlia Alshanetsky <iliaa@php.net>
Mon, 3 Mar 2008 21:12:16 +0000 (21:12 +0000)
ext/pdo/pdo_dbh.c

index 65a5735d2ce572e94bf368221e537eb400eea0e7..a9444c14770bc961cf4f7c4e9afb93d16bc567ba 100755 (executable)
@@ -992,7 +992,7 @@ static PHP_METHOD(PDO, errorInfo)
        pdo_dbh_t *dbh = zend_object_store_get_object(getThis() TSRMLS_CC);
 
        if (ZEND_NUM_ARGS()) {
-               RETURN_FALSE;
+               WRONG_PARAM_COUNT;
        }
        PDO_CONSTRUCT_CHECK;
 
@@ -1133,6 +1133,10 @@ static PHP_METHOD(PDO, getAvailableDrivers)
 {
        HashPosition pos;
        pdo_driver_t **pdriver;
+
+       if (ZEND_NUM_ARGS()) {
+               WRONG_PARAM_COUNT;
+       }
        
        array_init(return_value);