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

mongoc_bulk_operation_execute: ensure reply is initialized before returning #363

Closed
wants to merge 3 commits into from
Closed

Conversation

cschwarz-inco
Copy link
Contributor

The documentation for "mongoc_bulk_operation_execute" says "reply is always initialized, even upon failure. Callers must call bson_destroy() to release this potential allocation."

However, implementation does not initialize reply in all cases, making it impossible for the caller to determine whether reply has been initialized or not. This is contrary to documentation, which says that reply is ALWAYS initialized.

This commit changes the implementation to be in accordance with the documentation. reply is initialized before any return.

@ajdavis
Copy link
Member

ajdavis commented Jul 29, 2016

Thanks, we'll merge in the next few days.

@ajdavis
Copy link
Member

ajdavis commented Jul 29, 2016

@ajdavis
Copy link
Member

ajdavis commented Jul 29, 2016

Merged in 0e0ae00

@ajdavis ajdavis closed this Jul 29, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants