[PATCH] D38593: [sanitizer] Update scudo to use new API

Kostya Kortchinsky via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Nov 10 09:43:53 PST 2017


cryptoad added inline comments.


================
Comment at: lib/scudo/scudo_allocator_secondary.h:99
   void Deallocate(AllocatorStats *Stats, void *Ptr) {
-    SecondaryHeader *Header = getHeader(Ptr);
+    ReservedAddressRange *StoredRange = getReservedAddressRange(Ptr);
     {
----------------
You should be able to do directly `ReservedAddressRange AddressRange = *getReservedAddressRange(Ptr);` and then you don't have to use the StoredRange intermediate variable. Keep the comment though, but move it here.


https://reviews.llvm.org/D38593





More information about the llvm-commits mailing list