Skip to content

Commit 444f80e

Browse files
committed
Rebased onto other patch renaming Check() to check()
1 parent ecd477a commit 444f80e

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

compiler-rt/lib/gwp_asan/guarded_pool_allocator.cpp

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -52,12 +52,12 @@ void GuardedPoolAllocator::init(const options::Options &Opts) {
5252
Opts.MaxSimultaneousAllocations == 0)
5353
return;
5454

55-
Check(Opts.SampleRate >= 0, "GWP-ASan Error: SampleRate is < 0.");
56-
Check(Opts.SampleRate < (1 << 30), "GWP-ASan Error: SampleRate is >= 2^30.");
57-
Check(Opts.MaxSimultaneousAllocations >= 0,
55+
check(Opts.SampleRate >= 0, "GWP-ASan Error: SampleRate is < 0.");
56+
check(Opts.SampleRate < (1 << 30), "GWP-ASan Error: SampleRate is >= 2^30.");
57+
check(Opts.MaxSimultaneousAllocations >= 0,
5858
"GWP-ASan Error: MaxSimultaneousAllocations is < 0.");
5959

60-
Check(SingletonPtr == nullptr,
60+
check(SingletonPtr == nullptr,
6161
"There's already a live GuardedPoolAllocator!");
6262
SingletonPtr = this;
6363
Backtrace = Opts.Backtrace;

compiler-rt/lib/gwp_asan/utilities.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ void die(const char *Message);
2020
void dieWithErrorCode(const char *Message, int64_t ErrorCode);
2121

2222
// Checks that `Condition` is true, otherwise dies with `Message`.
23-
GWP_ASAN_ALWAYS_INLINE void Check(bool Condition, const char *Message) {
23+
GWP_ASAN_ALWAYS_INLINE void check(bool Condition, const char *Message) {
2424
if (GWP_ASAN_LIKELY(Condition))
2525
return;
2626
die(Message);

0 commit comments

Comments
 (0)