Skip to content

Commit 6ad2a63

Browse files
committed
Use XtOffsetOf to calculate zend_object offset
1 parent 98b5dfb commit 6ad2a63

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

src/zend_container.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -92,7 +92,7 @@ class zend_container
9292
}
9393
static inline bitem *bnode_fetch_object_data(zend_object *obj)
9494
{
95-
return (bitem *)(*((uintptr_t *)((char *)obj - sizeof(uintptr_t))));
95+
return (bitem *)(*((uintptr_t *)((char *)obj - XtOffsetOf(bitem_object, std))));
9696
}
9797
};
9898

0 commit comments

Comments
 (0)