You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@kudu.apache.org by "Adar Dembo (Code Review)" <ge...@cloudera.org> on 2017/08/23 23:58:25 UTC

[kudu-CR] remove control flow warnings

Hello Mike Percy,

I'd like you to do a code review.  Please visit

    http://gerrit.cloudera.org:8080/7794

to review the following change.

Change subject: remove control flow warnings
......................................................................

remove control flow warnings

This patch eliminates two -Wreturn-type warnings by adding default switch
statements that crash.

  ../../src/kudu/consensus/consensus_meta.cc: In member function ‘const kudu::consensus::RaftConfigPB& kudu::consensus::ConsensusMetadata::config_unlocked(kudu::consensus::RaftConfigState) const’:
  ../../src/kudu/consensus/consensus_meta.cc:136:1: warning: control reaches end of non-void function [-Wreturn-type]
   }

  ../../src/kudu/integration-tests/fuzz-itest.cc: In function ‘TestOpType kudu::tablet::PickOpAtRandom(kudu::tablet::TestOpSets)’:
  ../../src/kudu/integration-tests/fuzz-itest.cc:477:1: warning: control reaches end of non-void function [-Wreturn-type]
   }

Change-Id: I45ca805bc7db2e234f55d2c59efcf01a28593e12
---
M src/kudu/consensus/consensus_meta.cc
M src/kudu/integration-tests/fuzz-itest.cc
2 files changed, 3 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.cloudera.org:29418/kudu refs/changes/94/7794/1
-- 
To view, visit http://gerrit.cloudera.org:8080/7794
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I45ca805bc7db2e234f55d2c59efcf01a28593e12
Gerrit-PatchSet: 1
Gerrit-Project: kudu
Gerrit-Branch: master
Gerrit-Owner: Adar Dembo <ad...@cloudera.com>
Gerrit-Reviewer: Mike Percy <mp...@apache.org>

[kudu-CR] remove control flow warnings

Posted by "Mike Percy (Code Review)" <ge...@cloudera.org>.
Mike Percy has posted comments on this change.

Change subject: remove control flow warnings
......................................................................


Patch Set 1: Code-Review+2

-- 
To view, visit http://gerrit.cloudera.org:8080/7794
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I45ca805bc7db2e234f55d2c59efcf01a28593e12
Gerrit-PatchSet: 1
Gerrit-Project: kudu
Gerrit-Branch: master
Gerrit-Owner: Adar Dembo <ad...@cloudera.com>
Gerrit-Reviewer: Kudu Jenkins
Gerrit-Reviewer: Mike Percy <mp...@apache.org>
Gerrit-HasComments: No

[kudu-CR] remove control flow warnings

Posted by "Adar Dembo (Code Review)" <ge...@cloudera.org>.
Adar Dembo has posted comments on this change.

Change subject: remove control flow warnings
......................................................................


Patch Set 1: Verified+1

Unrelated test failure. I put up http://gerrit.cloudera.org:8080/7795 to help with it.

-- 
To view, visit http://gerrit.cloudera.org:8080/7794
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I45ca805bc7db2e234f55d2c59efcf01a28593e12
Gerrit-PatchSet: 1
Gerrit-Project: kudu
Gerrit-Branch: master
Gerrit-Owner: Adar Dembo <ad...@cloudera.com>
Gerrit-Reviewer: Adar Dembo <ad...@cloudera.com>
Gerrit-Reviewer: Kudu Jenkins
Gerrit-Reviewer: Mike Percy <mp...@apache.org>
Gerrit-HasComments: No

[kudu-CR] remove control flow warnings

Posted by "Adar Dembo (Code Review)" <ge...@cloudera.org>.
Adar Dembo has submitted this change and it was merged.

Change subject: remove control flow warnings
......................................................................


remove control flow warnings

This patch eliminates two -Wreturn-type warnings by adding default switch
statements that crash.

  ../../src/kudu/consensus/consensus_meta.cc: In member function ‘const kudu::consensus::RaftConfigPB& kudu::consensus::ConsensusMetadata::config_unlocked(kudu::consensus::RaftConfigState) const’:
  ../../src/kudu/consensus/consensus_meta.cc:136:1: warning: control reaches end of non-void function [-Wreturn-type]
   }

  ../../src/kudu/integration-tests/fuzz-itest.cc: In function ‘TestOpType kudu::tablet::PickOpAtRandom(kudu::tablet::TestOpSets)’:
  ../../src/kudu/integration-tests/fuzz-itest.cc:477:1: warning: control reaches end of non-void function [-Wreturn-type]
   }

Change-Id: I45ca805bc7db2e234f55d2c59efcf01a28593e12
Reviewed-on: http://gerrit.cloudera.org:8080/7794
Reviewed-by: Mike Percy <mp...@apache.org>
Tested-by: Adar Dembo <ad...@cloudera.com>
---
M src/kudu/consensus/consensus_meta.cc
M src/kudu/integration-tests/fuzz-itest.cc
2 files changed, 3 insertions(+), 0 deletions(-)

Approvals:
  Mike Percy: Looks good to me, approved
  Adar Dembo: Verified



-- 
To view, visit http://gerrit.cloudera.org:8080/7794
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I45ca805bc7db2e234f55d2c59efcf01a28593e12
Gerrit-PatchSet: 2
Gerrit-Project: kudu
Gerrit-Branch: master
Gerrit-Owner: Adar Dembo <ad...@cloudera.com>
Gerrit-Reviewer: Adar Dembo <ad...@cloudera.com>
Gerrit-Reviewer: Mike Percy <mp...@apache.org>