diff options
author | Ivan Maidanski <ivmai@mail.ru> | 2022-09-27 19:55:32 +0300 |
---|---|---|
committer | Ivan Maidanski <ivmai@mail.ru> | 2022-09-27 19:55:32 +0300 |
commit | 0d19067c37097e3384a4e2a65910cc158bbdfd58 (patch) | |
tree | 500faf7924fc61333f69e17d5094326701cc7e4d /ptr_chck.c | |
parent | f55f26caf1f4a5ff17364a955162db7c5bdf273f (diff) | |
download | bdwgc-0d19067c37097e3384a4e2a65910cc158bbdfd58.tar.gz |
Fix disabling of automatic dynamic libraries registration
Now, if GC_no_dls then GC_is_visible does not cause registration of
dynamic libraries.
* ptr_chck.c [!THREADS && (DYNAMIC_LOADING || MSWIN32 || MSWINCE
|| CYGWIN32 || PCR)] (GC_is_visible): Do not call
GC_register_dynamic_libraries() followed by GC_is_static_root()
if GC_no_dls.
Diffstat (limited to 'ptr_chck.c')
-rw-r--r-- | ptr_chck.c | 6 |
1 files changed, 4 insertions, 2 deletions
@@ -208,8 +208,10 @@ GC_API void * GC_CALL GC_is_visible(void *p) /* Else do it again correctly: */ # if defined(DYNAMIC_LOADING) || defined(MSWIN32) \ || defined(MSWINCE) || defined(CYGWIN32) || defined(PCR) - GC_register_dynamic_libraries(); - if (GC_is_static_root(p)) return p; + if (!GC_no_dls) { + GC_register_dynamic_libraries(); + if (GC_is_static_root(p)) return p; + } # endif goto fail; } else { |