Skip to content

Commit 1a8f084

Browse files
Merge pull request ceph#62673 from adamemerson/wip-test-osd-signed-comparison
test/osd: Fix signed comparison warning
2 parents fd13a17 + ef42ddb commit 1a8f084

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/test/osd/TestOSDMap.cc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -426,7 +426,7 @@ class OSDMapTest : public testing::Test,
426426
cout << "<<<<<PGs distribution:" << std::endl;
427427
}
428428
int high_load_after = 0;
429-
for (auto i = 0 ; i < weights.size() ; i++) {
429+
for (auto i = 0 ; std::cmp_less(i, weights.size()) ; i++) {
430430
int pgs = pgs_by_osd[i].size();
431431
int prims = prim_pgs_by_osd[i].size();
432432
int cur_load = prims * 100 + (pgs - prims) * (100 - rr);

0 commit comments

Comments
 (0)