summaryrefslogtreecommitdiff
path: root/lib/scudo/scudo_allocator.cpp
diff options
context:
space:
mode:
authorAlex Shlyapnikov <alekseys@google.com>2017-06-29 21:54:38 +0000
committerAlex Shlyapnikov <alekseys@google.com>2017-06-29 21:54:38 +0000
commit28b9d0a32fb203911935a6f723cd46843f381b14 (patch)
tree4e3410b3e8274a70dbd472da5bc6d431fc2d098c /lib/scudo/scudo_allocator.cpp
parent2cd50a16aec00d8d739ff8a8f669027fef286c1d (diff)
Merge
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@306748 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/scudo/scudo_allocator.cpp')
-rw-r--r--lib/scudo/scudo_allocator.cpp3
1 files changed, 1 insertions, 2 deletions
diff --git a/lib/scudo/scudo_allocator.cpp b/lib/scudo/scudo_allocator.cpp
index a2a3c8ba3..00fa19218 100644
--- a/lib/scudo/scudo_allocator.cpp
+++ b/lib/scudo/scudo_allocator.cpp
@@ -580,8 +580,7 @@ struct ScudoAllocator {
void *calloc(uptr NMemB, uptr Size) {
initThreadMaybe();
- // TODO(kostyak): switch to CheckForCallocOverflow once D34799 lands.
- if (CallocShouldReturnNullDueToOverflow(NMemB, Size))
+ if (CheckForCallocOverflow(NMemB, Size))
return FailureHandler::OnBadRequest();
return allocate(NMemB * Size, MinAlignment, FromMalloc, true);
}