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

Add fix for get si npe #929

Merged
merged 1 commit into from
May 4, 2018
Merged

Conversation

eriknelson
Copy link
Contributor

@shawn-hurley and I discovered a panic this morning. If for some reason the catalog has a bunch of instances that the broker is unaware of, the broker will try to lookup the instance, fail to find it, and panic when trying to deref the spec off a nil value. This correctly checks the error.

@openshift-ci-robot openshift-ci-robot added the size/S Denotes a PR that changes 10-29 lines, ignoring generated files. label May 4, 2018
@shawn-hurley
Copy link
Contributor

Pretty soon we can start to write tests for the broker if we want. We have mocked for dao and we just need to figure out the mocks for apb.Executor/async engine. Just a thought for later

Copy link
Contributor

@jmrodri jmrodri left a comment

Choose a reason for hiding this comment

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

Yep, accessing the instance before checking the error is definitely a potential null pointer exception :) ACK

@jmrodri jmrodri merged commit 275fbe3 into openshift:master May 4, 2018
@eriknelson eriknelson deleted the fix-si-get-npe branch May 4, 2018 18:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
size/S Denotes a PR that changes 10-29 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants