diff options
author | Kaz Kylheku <kaz@kylheku.com> | 2023-05-11 08:00:50 -0700 |
---|---|---|
committer | Kaz Kylheku <kaz@kylheku.com> | 2023-05-11 08:00:50 -0700 |
commit | dce942fb5980eb7b25bd08ee7e9f5ef2f3a97ff8 (patch) | |
tree | 1c42e67cf2e414019f5f6d82111efa755194aa77 /gc.c | |
parent | 823de0fec90d40a62a573efaac074fbc72293bdd (diff) | |
download | txr-dce942fb5980eb7b25bd08ee7e9f5ef2f3a97ff8.tar.gz txr-dce942fb5980eb7b25bd08ee7e9f5ef2f3a97ff8.tar.bz2 txr-dce942fb5980eb7b25bd08ee7e9f5ef2f3a97ff8.zip |
android: restore pointer tag in gc_free_all.
* gc.c (gc_free_all): Just like we do in the sweep function,
we must mask back the pointer tag that we removed from
the heap object's pointer, before handing the pointer to
the free function. Starting in Android 11, the pointer
tagging is more strict. It was not enforced previously; now
our logic for stripping and restoring the tags is actualy
being tested.
Diffstat (limited to 'gc.c')
-rw-r--r-- | gc.c | 4 |
1 files changed, 4 insertions, 0 deletions
@@ -1279,7 +1279,11 @@ void gc_free_all(void) finalize(block); } +#if CONFIG_NAN_BOXING_STRIP_TAG + free(coerce(heap_t *, coerce(ucnum, iter) | (iter->tag << TAG_BIGSHIFT))); +#else free(iter); +#endif iter = next; } } |