Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

a split on string can give empty elements - fix bz1421572 #12944

Merged
merged 1 commit into from
Feb 15, 2017

Conversation

rajatchopra
Copy link
Contributor

@rajatchopra rajatchopra commented Feb 13, 2017

Fix for: https://bugzilla.redhat.com/show_bug.cgi?id=1421572
A strings.split("/") gives two elements, both empty. And we would barf without this fix. Also for any path that ends with a "/" will give an empty last element.

cc @knobunc @openshift/networking

Copy link
Contributor

@knobunc knobunc left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. Is there a test we can add to cover this case?

@knobunc
Copy link
Contributor

knobunc commented Feb 13, 2017

[test]

@openshift-bot
Copy link
Contributor

Evaluated for origin test up to 6ea8ae8

@rajatchopra
Copy link
Contributor Author

@knobunc A unit test case will not be useful, the error is at F5 REST api (empty condition is not ignored).

@knobunc
Copy link
Contributor

knobunc commented Feb 14, 2017

@rajatchopra got it. Thanks

@openshift-bot
Copy link
Contributor

continuous-integration/openshift-jenkins/test SUCCESS (https://ci.openshift.redhat.com/jenkins/job/test_pull_requests_origin_future/179/) (Base Commit: bd3e362)

@knobunc
Copy link
Contributor

knobunc commented Feb 14, 2017

[merge]

@openshift-bot
Copy link
Contributor

Evaluated for origin merge up to 6ea8ae8

@openshift-bot
Copy link
Contributor

openshift-bot commented Feb 15, 2017

continuous-integration/openshift-jenkins/merge SUCCESS (https://ci.openshift.redhat.com/jenkins/job/test_pull_requests_origin_future/211/) (Base Commit: 2d3b39c) (Image: devenv-rhel7_5915)

@openshift-bot openshift-bot merged commit 6fc3d0a into openshift:master Feb 15, 2017
@rajatchopra rajatchopra deleted the f5_pathfix branch February 22, 2017 20:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants