summaryrefslogtreecommitdiff
path: root/storaged
diff options
context:
space:
mode:
authorChih-Hung Hsieh <chh@google.com>2023-01-11 14:21:46 -0800
committerChih-Hung Hsieh <chh@google.com>2023-01-11 14:21:46 -0800
commitdfd1d517b130a5874b5496ac976798f8ef93d7f6 (patch)
tree102896aa70b28ad6c6065a733b43ac9eea15a480 /storaged
parentb333a400c96c6efe27adc0ec2be10bcba2a83466 (diff)
downloadcore-dfd1d517b130a5874b5496ac976798f8ef93d7f6.tar.gz
Suppress clang-analyzer-security.FloatLoopCounter warnings
* Suppress also the alias check name cert-flp30-c. * Leave comment in code for code owners to rewrite the loop with integer counters. Bug: 265171053 Test: presubmit; tidy-system-core-storaged_subset Change-Id: I8297161366a7a2e1c7cdbec8efb7a8e9e435166a
Diffstat (limited to 'storaged')
-rw-r--r--storaged/tests/storaged_test.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/storaged/tests/storaged_test.cpp b/storaged/tests/storaged_test.cpp
index bb71bf3c2..9a281c2fe 100644
--- a/storaged/tests/storaged_test.cpp
+++ b/storaged/tests/storaged_test.cpp
@@ -284,6 +284,8 @@ TEST(storaged_test, disk_stats_monitor) {
dsm_detect.update_mean();
dsm_detect.update_std();
+ // FixLater: avoid floating point loop counters
+ // NOLINTNEXTLINE(clang-analyzer-security.FloatLoopCounter,cert-flp30-c)
for (double i = 0; i < 2 * dsm_detect.mSigma; i += 0.5) {
struct disk_perf test_perf;
struct disk_perf test_mean = dsm_detect.mMean;