diff options
| -rwxr-xr-x | ext/pdo/pdo_dbh.c | 2 | ||||
| -rwxr-xr-x | ext/pdo/tests/pdo_030.phpt | 17 |
2 files changed, 16 insertions, 3 deletions
diff --git a/ext/pdo/pdo_dbh.c b/ext/pdo/pdo_dbh.c index fd5cf11893..2e133da5a3 100755 --- a/ext/pdo/pdo_dbh.c +++ b/ext/pdo/pdo_dbh.c @@ -827,7 +827,7 @@ static PHP_METHOD(PDO, getAttribute) case PDO_ATTR_STATEMENT_CLASS: array_init(return_value); - add_next_index_string(return_value, dbh->def_stmt_ce->name, 1); + add_next_index_text(return_value, dbh->def_stmt_ce->name, 1); if (dbh->def_stmt_ctor_args) { dbh->def_stmt_ctor_args->refcount++; add_next_index_zval(return_value, dbh->def_stmt_ctor_args); diff --git a/ext/pdo/tests/pdo_030.phpt b/ext/pdo/tests/pdo_030.phpt index e9d5475401..7c260afec0 100755 --- a/ext/pdo/tests/pdo_030.phpt +++ b/ext/pdo/tests/pdo_030.phpt @@ -137,13 +137,26 @@ array(3) { ===DONE=== PDODatabase::__destruct() PDOStatementX::__destruct() ---UEXPECT-- +--UEXPECTF-- unicode(11) "PDODatabase" unicode(12) "PDOStatement" ===QUERY=== +array(1) { + [0]=> + unicode(12) "PDOStatement" +} +array(2) { + [0]=> + unicode(13) "PDOStatementX" + [1]=> + array(1) { + [0]=> + object(PDODatabase)#%d (0) { + } + } +} PDODatabase::query() PDOStatementX::__construct() -PDOStatementX::execute() unicode(13) "PDOStatementX" unicode(11) "PDODatabase" ===FOREACH=== |
