Skip to content

Commit 99f30d4

Browse files
Avoid uninitialized memory
1 parent 39b1d09 commit 99f30d4

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Zend/zend_attributes.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -502,7 +502,7 @@ ZEND_API zend_internal_attribute *zend_mark_internal_attribute(zend_class_entry
502502
if (zend_string_equals(attr->name, zend_ce_attribute->name)) {
503503
internal_attr = pemalloc(sizeof(zend_internal_attribute), 1);
504504
internal_attr->ce = ce;
505-
if (Z_TYPE(attr->args[0].value) == IS_NULL) {
505+
if (attr->argc == 0) {
506506
// Apply default of Attribute::TARGET_ALL
507507
internal_attr->flags = ZEND_ATTRIBUTE_TARGET_ALL;
508508
} else {

0 commit comments

Comments
 (0)