Hi Collin, Thanks for investigating.
> If you go into gdb and set a break point at __getdelim and continue you > will end up at __interceptor_trampoline___getdelim. ... which means that it gets redirected into the ASAN/UBSAN library. > How about the attached patch to avoid the symbol when glibc is used but > it is not using extern inlines? > # if __GLIBC__ >= 2 && defined __USE_EXTERN_INLINES __USE_EXTERN_INLINES depends on the optimization level. It is not uncommon, when building a package, that different object files are compiled with different optimization levels. This could thus lead to an undefined symbol at link time. > It works with my machine with 'clang -O3 -fsanitize=address', > so I assume optimizations are disabled once '-fsanitize' is used. That looks weird and strange. I would better avoid this fragile route. How about skipping this part of the test if ASAN is enabled? This can be done through this idiom, already used in a couple of test files: #ifndef __has_feature # define __has_feature(a) 0 #endif #if defined __SANITIZE_ADDRESS__ || __has_feature (address_sanitizer) Bruno
