forked from OSchip/llvm-project
[NFC][asan] Don't unwind stack before pool check
This commit is contained in:
parent
eb4efa8832
commit
6cf72ad3b3
|
@ -120,19 +120,19 @@ static void *ReallocFromLocalPool(void *ptr, uptr size) {
|
|||
}
|
||||
|
||||
INTERCEPTOR(void, free, void *ptr) {
|
||||
GET_STACK_TRACE_FREE;
|
||||
if (UNLIKELY(IsInDlsymAllocPool(ptr))) {
|
||||
DeallocateFromLocalPool(ptr);
|
||||
return;
|
||||
}
|
||||
GET_STACK_TRACE_FREE;
|
||||
asan_free(ptr, &stack, FROM_MALLOC);
|
||||
}
|
||||
|
||||
#if SANITIZER_INTERCEPT_CFREE
|
||||
INTERCEPTOR(void, cfree, void *ptr) {
|
||||
GET_STACK_TRACE_FREE;
|
||||
if (UNLIKELY(IsInDlsymAllocPool(ptr)))
|
||||
return;
|
||||
GET_STACK_TRACE_FREE;
|
||||
asan_free(ptr, &stack, FROM_MALLOC);
|
||||
}
|
||||
#endif // SANITIZER_INTERCEPT_CFREE
|
||||
|
@ -304,4 +304,4 @@ void ReplaceSystemMalloc() {
|
|||
#endif // SANITIZER_ANDROID
|
||||
|
||||
#endif // SANITIZER_FREEBSD || SANITIZER_FUCHSIA || SANITIZER_LINUX ||
|
||||
// SANITIZER_NETBSD || SANITIZER_SOLARIS
|
||||
// SANITIZER_NETBSD || SANITIZER_SOLARIS
|
Loading…
Reference in New Issue