Skip to content

Commit 6b94780

Browse files
committed
Fix leak of ObjectIdDict keys
Replace dead keys with jl_nothing. Fix #10960.
1 parent 3ff49ff commit 6b94780

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

src/table.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -138,6 +138,7 @@ jl_value_t *jl_eqtable_pop(jl_array_t *h, void *key, jl_value_t *deflt)
138138
if (bp == NULL || *bp == NULL)
139139
return deflt;
140140
jl_value_t *val = (jl_value_t*)*bp;
141+
*(bp-1) = jl_nothing; // clear the key
141142
*bp = NULL;
142143
return val;
143144
}

0 commit comments

Comments
 (0)