This is an automated email from the ASF dual-hosted git repository.
alexey pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/kudu.git
The following commit(s) were added to refs/heads/master by this push:
new 35aa458d7 [compile] fix a compile warning
35aa458d7 is described below
commit 35aa458d7a5f67caf0ef4111408885fa5ba0b532
Author: kedeng <[email protected]>
AuthorDate: Tue Jul 11 14:56:39 2023 +0800
[compile] fix a compile warning
I noticed that there is a warning during the compile
process:
`
/data/github-kudu/kudu/src/kudu/integration-tests/auto_incrementing-itest.cc:
In member function ‘virtual void
kudu::itest::AutoIncrementingItest_BootstrapWalsDiverge_Test::TestBody()’:
/data/github-kudu/kudu/src/kudu/integration-tests/auto_incrementing-itest.cc:530:7:
warning: operation on ‘j’ may be undefined [-Wsequence-point]
j = ++j % kNumTabletServers;
~~^~~~~~~~~~~~~~~~~~~~~~~~~
`
Although it does not involve functional defects, it
still needs to be fixed.
As it does not involve any logic changes, no new unit
tests have been added.
Change-Id: I125674ad3bfcc14ae5077b84d6f3d01fcacd1e08
Reviewed-on: http://gerrit.cloudera.org:8080/20182
Reviewed-by: Alexey Serbin <[email protected]>
Tested-by: Alexey Serbin <[email protected]>
---
src/kudu/integration-tests/auto_incrementing-itest.cc | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/kudu/integration-tests/auto_incrementing-itest.cc
b/src/kudu/integration-tests/auto_incrementing-itest.cc
index 8d72bd46f..4c49bde02 100644
--- a/src/kudu/integration-tests/auto_incrementing-itest.cc
+++ b/src/kudu/integration-tests/auto_incrementing-itest.cc
@@ -527,7 +527,7 @@ TEST_F(AutoIncrementingItest, BootstrapWalsDiverge) {
vector<string> result;
ASSERT_OK(ScanTablet(j, tablet_uuid, &result));
results.emplace_back(result);
- j = ++j % kNumTabletServers;
+ j = (j + 1) % kNumTabletServers;
}
ASSERT_EQ(kNumTabletServers, results.size());
for (int i = 0; i < kNumTabletServers - 1; i++) {