aboutsummaryrefslogtreecommitdiff
path: root/absl/algorithm/algorithm_test.cc
diff options
context:
space:
mode:
authorAbseil Team <absl-team@google.com>2023-02-23 13:05:39 -0800
committerCopybara-Service <copybara-worker@google.com>2023-02-23 13:06:27 -0800
commit4825ef40953aeb4a71e3625203b760381da6b0d7 (patch)
treed8931476e759cd07d9b22ebad887700161b7e725 /absl/algorithm/algorithm_test.cc
parent6d16237574fed8538a4864954a5e2b5a098f32f2 (diff)
downloadabseil-4825ef40953aeb4a71e3625203b760381da6b0d7.tar.gz
abseil-4825ef40953aeb4a71e3625203b760381da6b0d7.tar.bz2
abseil-4825ef40953aeb4a71e3625203b760381da6b0d7.zip
Initialize ScopedMockLog.is_triggered_ with false.
In C++20, this happens by default, but in C++17, it's left uninitialized if no logs are sent and StartCapturingLogs is never called. The destructor then makes an attempt to access it, which is both unsafe and not very useful while it is uninitialized. Also add a test that expects the appropriate CHECK fail when StartCapturingLogs is not called. PiperOrigin-RevId: 511865440 Change-Id: Ie23ff3f901e926761d5f487e10d33c21c3bd43d3
Diffstat (limited to 'absl/algorithm/algorithm_test.cc')
0 files changed, 0 insertions, 0 deletions