summaryrefslogtreecommitdiff
path: root/ext/mysqli/mysqli.c
diff options
context:
space:
mode:
Diffstat (limited to 'ext/mysqli/mysqli.c')
-rw-r--r--ext/mysqli/mysqli.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/ext/mysqli/mysqli.c b/ext/mysqli/mysqli.c
index 0d1b34db9e..47539b717c 100644
--- a/ext/mysqli/mysqli.c
+++ b/ext/mysqli/mysqli.c
@@ -198,6 +198,11 @@ zval *mysqli_read_property(zval *object, zval *member, int type TSRMLS_DC)
ret = FAILURE;
obj = (mysqli_object *)zend_objects_get_address(object TSRMLS_CC);
+ /* object was already destroyed */
+ if (!obj->ptr) {
+ retval = EG(uninitialized_zval_ptr);
+ return(retval);
+ }
if (member->type != IS_STRING) {
tmp_member = *member;