diff --git a/compiler-rt/lib/scudo/standalone/mem_map_base.h b/compiler-rt/lib/scudo/standalone/mem_map_base.h --- a/compiler-rt/lib/scudo/standalone/mem_map_base.h +++ b/compiler-rt/lib/scudo/standalone/mem_map_base.h @@ -50,8 +50,7 @@ void setMemoryPermission(uptr Addr, uptr Size, uptr Flags) { DCHECK(isAllocated()); DCHECK((Addr >= getBase()) && (Addr + Size <= getBase() + getCapacity())); - return static_cast(this)->setMemoryPermissionImpl(Addr, Size, - Flags); + return invokeImpl(&Derived::setMemoryPermissionImpl, Addr, Size, Flags); } // Suggest releasing a set of contiguous physical pages back to the OS. Note