]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
test/common: Fix signed comparison 62672/head
authorAdam Emerson <aemerson@redhat.com>
Thu, 28 Nov 2024 05:17:29 +0000 (00:17 -0500)
committerAdam C. Emerson <aemerson@redhat.com>
Thu, 3 Apr 2025 22:02:40 +0000 (18:02 -0400)
Signed-off-by: Adam Emerson <aemerson@redhat.com>
src/test/common/test_hobject.cc

index 9f994cb7d95b5c78aaa55e3f129822e85947c00e..6916b9fce38a987a7834fe044ff83f56be88be3a 100644 (file)
@@ -285,7 +285,7 @@ TEST(HObject, fmt_random)
 
     auto name_length = (i * 17) % 51;
     std::string name;
-    for (int j = 0; j < name_length; j++) {
+    for (int j = 0; std::cmp_less(j, name_length); j++) {
       name.push_back((i * name_length + j) % 256);
     }