[compiler-rt] 7abd683 - [scudo] Use nullptr instead of integer-to-pointer cast
Dominic Chen via llvm-commits
llvm-commits at lists.llvm.org
Thu Mar 17 10:17:55 PDT 2022
Author: Dominic Chen
Date: 2022-03-17T10:17:36-07:00
New Revision: 7abd6837a0a0bc256ff1c4ec458ec1fa935eb687
URL: https://github.com/llvm/llvm-project/commit/7abd6837a0a0bc256ff1c4ec458ec1fa935eb687
DIFF: https://github.com/llvm/llvm-project/commit/7abd6837a0a0bc256ff1c4ec458ec1fa935eb687.diff
LOG: [scudo] Use nullptr instead of integer-to-pointer cast
Differential Revision: https://reviews.llvm.org/D121856
Added:
Modified:
compiler-rt/lib/scudo/standalone/combined.h
Removed:
################################################################################
diff --git a/compiler-rt/lib/scudo/standalone/combined.h b/compiler-rt/lib/scudo/standalone/combined.h
index 371fb783a06eb..365720d4a5f4f 100644
--- a/compiler-rt/lib/scudo/standalone/combined.h
+++ b/compiler-rt/lib/scudo/standalone/combined.h
@@ -1271,8 +1271,8 @@ class Allocator {
}
static const size_t NumErrorReports =
- sizeof(((scudo_error_info *)0)->reports) /
- sizeof(((scudo_error_info *)0)->reports[0]);
+ sizeof(((scudo_error_info *)nullptr)->reports) /
+ sizeof(((scudo_error_info *)nullptr)->reports[0]);
static void getInlineErrorInfo(struct scudo_error_info *ErrorInfo,
size_t &NextErrorReport, uintptr_t FaultAddr,
More information about the llvm-commits
mailing list