summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNick Kledzik <kledzik@apple.com>2014-01-28 23:25:13 +0000
committerNick Kledzik <kledzik@apple.com>2014-01-28 23:25:13 +0000
commitffcc42764e6915c99e9118285f699701126b7063 (patch)
treebdc707e8cdad397136637290b271e7ba3a215a05
parented139ac3659dff7385946ed140784a1227def411 (diff)
downloadllvm-ffcc42764e6915c99e9118285f699701126b7063.tar.gz
llvm-ffcc42764e6915c99e9118285f699701126b7063.tar.bz2
llvm-ffcc42764e6915c99e9118285f699701126b7063.tar.xz
Be more explicit about which overloaded variant to use. Caught by ASan!
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@200353 91177308-0d34-0410-b5e6-96231b3b80d8
-rw-r--r--include/llvm/Support/Allocator.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/include/llvm/Support/Allocator.h b/include/llvm/Support/Allocator.h
index d259415bc3..275086bffd 100644
--- a/include/llvm/Support/Allocator.h
+++ b/include/llvm/Support/Allocator.h
@@ -211,7 +211,7 @@ public:
typename enable_if<isPodLike<T>, ArrayRef<T> >::type
allocateCopy(ArrayRef<T> Src) {
size_t Length = Src.size();
- T *P = allocateCopy(Src.data(), Length*sizeof(T));
+ T *P = allocateCopy<T>(Src.data(), Length);
return makeArrayRef(P, Length);
}