From: Antony Dovgal Date: Wed, 3 Dec 2008 10:18:42 +0000 (+0000) Subject: MFH X-Git-Tag: php-5.3.0alpha2~9 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=b9653b8358be22015121e642bca0c2cb9fae99f5;p=php MFH --- diff --git a/ext/pdo/pdo_stmt.c b/ext/pdo/pdo_stmt.c index f5b26555ea..f82261f6a8 100755 --- a/ext/pdo/pdo_stmt.c +++ b/ext/pdo/pdo_stmt.c @@ -2203,10 +2203,12 @@ static PHP_METHOD(PDOStatement, debugDumpParams) char *str; uint len; ulong num; + int res; - if (zend_hash_get_current_key_ex(stmt->bound_params, &str, &len, &num, 0, &pos) == HASH_KEY_IS_LONG) { + res = zend_hash_get_current_key_ex(stmt->bound_params, &str, &len, &num, 0, &pos); + if (res == HASH_KEY_IS_LONG) { php_stream_printf(out TSRMLS_CC, "Key: Position #%ld:\n", num); - } else { + } else if (res == HASH_KEY_IS_STRING) { php_stream_printf(out TSRMLS_CC, "Key: Name: [%d] %.*s\n", len, len, str); }