Skip to content

Check if f is valid before dereference #19

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

Closed
wants to merge 2 commits into from

Conversation

ya1gaurav
Copy link
Contributor

file = f at line no 228.
file is checked against NULL at 232, but f is not checked. Adding null check.

file = f at line no 228.
file is checked against NULL at 232, but f is not checked. Adding null check.
@jzmaddock
Copy link
Collaborator

The existing check is redundant actually - the only places where that constructor is called, the mapfile pointer comes from "this" which is always non-null. Changed to an assert.

@ya1gaurav
Copy link
Contributor Author

Added BOOST_ASSERT instead of Null check,

@jzmaddock
Copy link
Collaborator

Apologies for not being clear, I've already made this change to develop: e824ddb

Thanks, John.

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.

2 participants