Update __sanitizer_get_allocated_begin to return const void*
authorThurston Dang <thurston@google.com>
Tue, 4 Apr 2023 00:42:37 +0000 (00:42 +0000)
committerThurston Dang <thurston@google.com>
Tue, 4 Apr 2023 00:43:36 +0000 (00:43 +0000)
commitd644ab022a7be985255db29fd466798e9b138bee
treecaa4cef20081b0b35142c5617b57018ac724c4a1
parent321d02cc6b6a1116c227c172249b5cacf4d0deba
Update __sanitizer_get_allocated_begin to return const void*

D147005 introduced __sanitizer_get_allocated_begin, with a return
value of void*. This involved a few naughty casts that dropped the
const. This patch adds back the const qualifier.

Differential Revision: https://reviews.llvm.org/D147489
compiler-rt/include/sanitizer/allocator_interface.h
compiler-rt/lib/asan/asan_allocator.cpp
compiler-rt/lib/dfsan/dfsan_allocator.cpp
compiler-rt/lib/hwasan/hwasan_allocator.cpp
compiler-rt/lib/lsan/lsan_allocator.cpp
compiler-rt/lib/memprof/memprof_allocator.cpp
compiler-rt/lib/msan/msan_allocator.cpp
compiler-rt/lib/sanitizer_common/sanitizer_allocator_interface.h
compiler-rt/lib/tsan/rtl/tsan_mman.cpp
compiler-rt/test/sanitizer_common/TestCases/get_allocated_begin.cpp