You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@kudu.apache.org by "Andrew Wong (Code Review)" <ge...@cloudera.org> on 2016/06/24 21:02:05 UTC
[kudu-CR] Make ParseAddressList not OK empty address lists
Andrew Wong has uploaded a new change for review.
http://gerrit.cloudera.org:8080/3486
Change subject: Make ParseAddressList not OK empty address lists
......................................................................
Make ParseAddressList not OK empty address lists
ParseAddressList would return Status::OK, even when called to parse
an empty list of addresses. In some cases (KUDU-1490), this could
lead to a segfault if the caller doesn't check to see if the returned
vector is empty and tries to access the returned elements.
Current usages of ParseAddressList don't seem to have a standard behavior
that makes sense when called with an empty address string. Instead,
ParseAddressList should do the check and return Status::InvalidArgument.
Change-Id: Idedc2ad9f2ab321a5bb7aa65ea59b8f1a4186377
---
M src/kudu/tools/kudu-ksck.cc
M src/kudu/util/net/net_util.cc
2 files changed, 4 insertions(+), 1 deletion(-)
git pull ssh://gerrit.cloudera.org:29418/kudu refs/changes/86/3486/1
--
To view, visit http://gerrit.cloudera.org:8080/3486
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-MessageType: newchange
Gerrit-Change-Id: Idedc2ad9f2ab321a5bb7aa65ea59b8f1a4186377
Gerrit-PatchSet: 1
Gerrit-Project: kudu
Gerrit-Branch: master
Gerrit-Owner: Andrew Wong <an...@cloudera.com>
[kudu-CR] Make ParseAddressList not OK empty address lists
Posted by "Todd Lipcon (Code Review)" <ge...@cloudera.org>.
Todd Lipcon has posted comments on this change.
Change subject: Make ParseAddressList not OK empty address lists
......................................................................
Patch Set 1:
(2 comments)
please add a test as well
http://gerrit.cloudera.org:8080/#/c/3486/1/src/kudu/tools/kudu-ksck.cc
File src/kudu/tools/kudu-ksck.cc:
Line 83: // return early if there were no addresses to parse
this could also happen if resolution failed, etc, right? not just the case of no addresses
http://gerrit.cloudera.org:8080/#/c/3486/1/src/kudu/util/net/net_util.cc
File src/kudu/util/net/net_util.cc:
Line 172:
nit: trailing whitespace
--
To view, visit http://gerrit.cloudera.org:8080/3486
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-MessageType: comment
Gerrit-Change-Id: Idedc2ad9f2ab321a5bb7aa65ea59b8f1a4186377
Gerrit-PatchSet: 1
Gerrit-Project: kudu
Gerrit-Branch: master
Gerrit-Owner: Andrew Wong <an...@cloudera.com>
Gerrit-Reviewer: Kudu Jenkins
Gerrit-Reviewer: Todd Lipcon <to...@apache.org>
Gerrit-HasComments: Yes
[kudu-CR] Make ParseAddressList not OK empty address lists
Posted by "Kudu Jenkins (Code Review)" <ge...@cloudera.org>.
Kudu Jenkins has posted comments on this change.
Change subject: Make ParseAddressList not OK empty address lists
......................................................................
Patch Set 1:
Build Started http://104.196.14.100/job/kudu-gerrit/1979/
--
To view, visit http://gerrit.cloudera.org:8080/3486
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-MessageType: comment
Gerrit-Change-Id: Idedc2ad9f2ab321a5bb7aa65ea59b8f1a4186377
Gerrit-PatchSet: 1
Gerrit-Project: kudu
Gerrit-Branch: master
Gerrit-Owner: Andrew Wong <an...@cloudera.com>
Gerrit-Reviewer: Kudu Jenkins
Gerrit-HasComments: No
[kudu-CR] Make ParseAddressList not OK empty address lists
Posted by "Kudu Jenkins (Code Review)" <ge...@cloudera.org>.
Kudu Jenkins has posted comments on this change.
Change subject: Make ParseAddressList not OK empty address lists
......................................................................
Patch Set 2:
Build Started http://104.196.14.100/job/kudu-gerrit/1980/
--
To view, visit http://gerrit.cloudera.org:8080/3486
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-MessageType: comment
Gerrit-Change-Id: Idedc2ad9f2ab321a5bb7aa65ea59b8f1a4186377
Gerrit-PatchSet: 2
Gerrit-Project: kudu
Gerrit-Branch: master
Gerrit-Owner: Andrew Wong <an...@cloudera.com>
Gerrit-Reviewer: Kudu Jenkins
Gerrit-Reviewer: Todd Lipcon <to...@apache.org>
Gerrit-HasComments: No
[kudu-CR] Make ParseAddressList not OK empty address lists
Posted by "Todd Lipcon (Code Review)" <ge...@cloudera.org>.
Todd Lipcon has posted comments on this change.
Change subject: Make ParseAddressList not OK empty address lists
......................................................................
Patch Set 3: Code-Review+2
--
To view, visit http://gerrit.cloudera.org:8080/3486
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-MessageType: comment
Gerrit-Change-Id: Idedc2ad9f2ab321a5bb7aa65ea59b8f1a4186377
Gerrit-PatchSet: 3
Gerrit-Project: kudu
Gerrit-Branch: master
Gerrit-Owner: Andrew Wong <an...@cloudera.com>
Gerrit-Reviewer: Kudu Jenkins
Gerrit-Reviewer: Todd Lipcon <to...@apache.org>
Gerrit-HasComments: No
[kudu-CR] Make ParseAddressList not OK empty address lists
Posted by "Kudu Jenkins (Code Review)" <ge...@cloudera.org>.
Kudu Jenkins has posted comments on this change.
Change subject: Make ParseAddressList not OK empty address lists
......................................................................
Patch Set 3:
Build Started http://104.196.14.100/job/kudu-gerrit/1981/
--
To view, visit http://gerrit.cloudera.org:8080/3486
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-MessageType: comment
Gerrit-Change-Id: Idedc2ad9f2ab321a5bb7aa65ea59b8f1a4186377
Gerrit-PatchSet: 3
Gerrit-Project: kudu
Gerrit-Branch: master
Gerrit-Owner: Andrew Wong <an...@cloudera.com>
Gerrit-Reviewer: Kudu Jenkins
Gerrit-Reviewer: Todd Lipcon <to...@apache.org>
Gerrit-HasComments: No
[kudu-CR] Make ParseAddressList not OK empty address lists
Posted by "Andrew Wong (Code Review)" <ge...@cloudera.org>.
Andrew Wong has uploaded a new patch set (#2).
Change subject: Make ParseAddressList not OK empty address lists
......................................................................
Make ParseAddressList not OK empty address lists
ParseAddressList would return Status::OK, even when called to parse
an empty list of addresses. In some cases (KUDU-1490), this could
lead to a segfault if the caller doesn't check to see if the returned
vector is empty and tries to access the returned elements.
Current usages of ParseAddressList don't seem to have a standard behavior
that makes sense when called with an empty address string. Instead,
ParseAddressList should do the check and return Status::InvalidArgument.
Change-Id: Idedc2ad9f2ab321a5bb7aa65ea59b8f1a4186377
---
M src/kudu/tools/kudu-ksck.cc
M src/kudu/util/net/net_util.cc
2 files changed, 4 insertions(+), 1 deletion(-)
git pull ssh://gerrit.cloudera.org:29418/kudu refs/changes/86/3486/2
--
To view, visit http://gerrit.cloudera.org:8080/3486
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-MessageType: newpatchset
Gerrit-Change-Id: Idedc2ad9f2ab321a5bb7aa65ea59b8f1a4186377
Gerrit-PatchSet: 2
Gerrit-Project: kudu
Gerrit-Branch: master
Gerrit-Owner: Andrew Wong <an...@cloudera.com>
Gerrit-Reviewer: Kudu Jenkins
Gerrit-Reviewer: Todd Lipcon <to...@apache.org>
[kudu-CR] Make ParseAddressList not OK empty address lists
Posted by "Todd Lipcon (Code Review)" <ge...@cloudera.org>.
Todd Lipcon has submitted this change and it was merged.
Change subject: Make ParseAddressList not OK empty address lists
......................................................................
Make ParseAddressList not OK empty address lists
ParseAddressList would return Status::OK, even when called to parse
an empty list of addresses. In some cases (KUDU-1490), this could
lead to a segfault if the caller doesn't check to see if the returned
vector is empty and tries to access the returned elements.
Current usages of ParseAddressList don't seem to have a standard behavior
that makes sense when called with an empty address string. Instead,
ParseAddressList should do the check and return Status::InvalidArgument.
Change-Id: Idedc2ad9f2ab321a5bb7aa65ea59b8f1a4186377
Reviewed-on: http://gerrit.cloudera.org:8080/3486
Tested-by: Kudu Jenkins
Reviewed-by: Todd Lipcon <to...@apache.org>
---
M src/kudu/tools/kudu-ksck.cc
M src/kudu/util/net/net_util.cc
2 files changed, 3 insertions(+), 1 deletion(-)
Approvals:
Todd Lipcon: Looks good to me, approved
Kudu Jenkins: Verified
--
To view, visit http://gerrit.cloudera.org:8080/3486
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-MessageType: merged
Gerrit-Change-Id: Idedc2ad9f2ab321a5bb7aa65ea59b8f1a4186377
Gerrit-PatchSet: 4
Gerrit-Project: kudu
Gerrit-Branch: master
Gerrit-Owner: Andrew Wong <an...@cloudera.com>
Gerrit-Reviewer: Kudu Jenkins
Gerrit-Reviewer: Todd Lipcon <to...@apache.org>
[kudu-CR] Make ParseAddressList not OK empty address lists
Posted by "Andrew Wong (Code Review)" <ge...@cloudera.org>.
Hello Kudu Jenkins,
I'd like you to reexamine a change. Please visit
http://gerrit.cloudera.org:8080/3486
to look at the new patch set (#3).
Change subject: Make ParseAddressList not OK empty address lists
......................................................................
Make ParseAddressList not OK empty address lists
ParseAddressList would return Status::OK, even when called to parse
an empty list of addresses. In some cases (KUDU-1490), this could
lead to a segfault if the caller doesn't check to see if the returned
vector is empty and tries to access the returned elements.
Current usages of ParseAddressList don't seem to have a standard behavior
that makes sense when called with an empty address string. Instead,
ParseAddressList should do the check and return Status::InvalidArgument.
Change-Id: Idedc2ad9f2ab321a5bb7aa65ea59b8f1a4186377
---
M src/kudu/tools/kudu-ksck.cc
M src/kudu/util/net/net_util.cc
2 files changed, 3 insertions(+), 1 deletion(-)
git pull ssh://gerrit.cloudera.org:29418/kudu refs/changes/86/3486/3
--
To view, visit http://gerrit.cloudera.org:8080/3486
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-MessageType: newpatchset
Gerrit-Change-Id: Idedc2ad9f2ab321a5bb7aa65ea59b8f1a4186377
Gerrit-PatchSet: 3
Gerrit-Project: kudu
Gerrit-Branch: master
Gerrit-Owner: Andrew Wong <an...@cloudera.com>
Gerrit-Reviewer: Kudu Jenkins
Gerrit-Reviewer: Todd Lipcon <to...@apache.org>