Skip to content

Commit 7f0e5c0

Browse files
committed
revert changes to sanitizer_allocator
1 parent ebc3d0d commit 7f0e5c0

File tree

1 file changed

+1
-5
lines changed

1 file changed

+1
-5
lines changed

compiler-rt/lib/sanitizer_common/sanitizer_allocator.cpp

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -85,12 +85,8 @@ static void NORETURN ReportInternalAllocatorOutOfMemory(uptr requested_size) {
8585

8686
void *InternalAlloc(uptr size, InternalAllocatorCache *cache, uptr alignment) {
8787
void *p = RawInternalAlloc(size, cache, alignment);
88-
if (UNLIKELY(!p)) {
89-
if (AllocatorMayReturnNull()) {
90-
return nullptr;
91-
}
88+
if (UNLIKELY(!p))
9289
ReportInternalAllocatorOutOfMemory(size);
93-
}
9490
return p;
9591
}
9692

0 commit comments

Comments
 (0)