diff options
author | Reid Kleckner <rnk@google.com> | 2017-10-30 17:26:57 +0000 |
---|---|---|
committer | Reid Kleckner <rnk@google.com> | 2017-10-30 17:26:57 +0000 |
commit | c6577df3ffb9099626a0d8335c38a41362e11f66 (patch) | |
tree | 92b4d79a6721dee312949e18443e8aa2dfecdd88 | |
parent | a0eba2205796725858d1921bb5c0ce473cba8aa3 (diff) | |
download | compiler-rt-c6577df3ffb9099626a0d8335c38a41362e11f66.tar.gz |
Fix clang warnings in winasan code
There are two instances of -Wcast-qual and one of -Wsign-compare.
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@316930 91177308-0d34-0410-b5e6-96231b3b80d8
-rw-r--r-- | lib/sanitizer_common/sanitizer_win.cc | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/sanitizer_common/sanitizer_win.cc b/lib/sanitizer_common/sanitizer_win.cc index f1a74d3f2..42357f6aa 100644 --- a/lib/sanitizer_common/sanitizer_win.cc +++ b/lib/sanitizer_common/sanitizer_win.cc @@ -379,7 +379,7 @@ struct ModuleInfo { #if !SANITIZER_GO int CompareModulesBase(const void *pl, const void *pr) { - const ModuleInfo *l = (ModuleInfo *)pl, *r = (ModuleInfo *)pr; + const ModuleInfo *l = (const ModuleInfo *)pl, *r = (const ModuleInfo *)pr; if (l->base_address < r->base_address) return -1; return l->base_address > r->base_address; @@ -794,7 +794,7 @@ void BufferedStackTrace::SlowUnwindStack(uptr pc, u32 max_depth) { // FIXME: Compare with StackWalk64. // FIXME: Look at LLVMUnhandledExceptionFilter in Signals.inc size = CaptureStackBackTrace(1, Min(max_depth, kStackTraceMax), - (void**)trace, 0); + (void **)&trace_buffer[0], 0); if (size == 0) return; @@ -917,7 +917,7 @@ bool IsAccessibleMemoryRange(uptr beg, uptr size) { } bool SignalContext::IsStackOverflow() const { - return GetType() == EXCEPTION_STACK_OVERFLOW; + return (DWORD)GetType() == EXCEPTION_STACK_OVERFLOW; } void SignalContext::InitPcSpBp() { |