diff options
author | Peter Zhu <[email protected]> | 2023-10-27 11:00:12 -0400 |
---|---|---|
committer | Peter Zhu <[email protected]> | 2023-10-27 11:00:12 -0400 |
commit | 7979c009a762d9b447f7ef286af2d314b7c11a6c (patch) | |
tree | c6692ee497288df93f16c8f4c0438035102b0d1f /gc.c | |
parent | 26a05c42173f0f6ad188a28c3ea508b18b376d6b (diff) |
Fix bug for removed weak references
rb_darray_foreach gives a pointer to the entry, so we need to deference
it to read the value.
Diffstat (limited to 'gc.c')
-rw-r--r-- | gc.c | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -8281,7 +8281,7 @@ gc_update_weak_references(rb_objspace_t *objspace) size_t retained_weak_references_count = 0; VALUE **ptr_ptr; rb_darray_foreach(objspace->weak_references, i, ptr_ptr) { - if (!ptr_ptr) continue; + if (!*ptr_ptr) continue; VALUE obj = **ptr_ptr; |