Skip to content

Commit 037775b

Browse files
Avoid uninitialized memory
1 parent fd3ae60 commit 037775b

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
@@ -484,7 +484,7 @@ ZEND_API zend_internal_attribute *zend_mark_internal_attribute(zend_class_entry
484484
if (zend_string_equals(attr->name, zend_ce_attribute->name)) {
485485
internal_attr = pemalloc(sizeof(zend_internal_attribute), 1);
486486
internal_attr->ce = ce;
487-
if (Z_TYPE(attr->args[0].value) == IS_NULL) {
487+
if (attr->argc == 0) {
488488
// Apply default of Attribute::TARGET_ALL
489489
internal_attr->flags = ZEND_ATTRIBUTE_TARGET_ALL;
490490
} else {

0 commit comments

Comments
 (0)