From: Georg Richter Date: Wed, 4 Aug 2004 12:28:09 +0000 (+0000) Subject: fixed bug #29522 X-Git-Tag: PRE_ZEND_VM_DISPATCH_PATCH~244 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=161b37ffbc193b6d5d1c88f21a08d3c8488e01e2;p=php fixed bug #29522 --- diff --git a/ext/mysqli/mysqli.c b/ext/mysqli/mysqli.c index a51338ad33..875acefbff 100644 --- a/ext/mysqli/mysqli.c +++ b/ext/mysqli/mysqli.c @@ -200,6 +200,12 @@ zval *mysqli_read_property(zval *object, zval *member, int type TSRMLS_DC) ret = zend_hash_find(obj->prop_handler, Z_STRVAL_P(member), Z_STRLEN_P(member)+1, (void **) &hnd); } if (ret == SUCCESS) { + /* check if connection is still valid */ + if (!obj->ptr) { + retval = EG(uninitialized_zval_ptr); + return(retval); + } + ret = hnd->read_func(obj, &retval TSRMLS_CC); if (ret == SUCCESS) { /* ensure we're creating a temporary variable */