diff options
author | Stanislav Malyshev <stas@php.net> | 2015-03-22 18:17:47 -0700 |
---|---|---|
committer | Stanislav Malyshev <stas@php.net> | 2015-03-22 18:17:47 -0700 |
commit | fb83c76deec58f1fab17c350f04c9f042e5977d1 (patch) | |
tree | b37767f2507d2355fec620964b71abc358db798f | |
parent | 95b9c34f0222e02d83f837555c7198948a6732fb (diff) | |
download | php-git-fb83c76deec58f1fab17c350f04c9f042e5977d1.tar.gz |
Check that the type is correct
-rw-r--r-- | ext/standard/incomplete_class.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/ext/standard/incomplete_class.c b/ext/standard/incomplete_class.c index 1816ac4605..30c82e67e6 100644 --- a/ext/standard/incomplete_class.c +++ b/ext/standard/incomplete_class.c @@ -144,7 +144,7 @@ PHPAPI char *php_lookup_class_name(zval *object, zend_uint *nlen) object_properties = Z_OBJPROP_P(object); - if (zend_hash_find(object_properties, MAGIC_MEMBER, sizeof(MAGIC_MEMBER), (void **) &val) == SUCCESS) { + if (zend_hash_find(object_properties, MAGIC_MEMBER, sizeof(MAGIC_MEMBER), (void **) &val) == SUCCESS && Z_TYPE_PP(val) == IS_STRING) { retval = estrndup(Z_STRVAL_PP(val), Z_STRLEN_PP(val)); if (nlen) { |