Fix a segfault when passing a null response to the sync methods

This commit is contained in:
Neel Goyal 2014-01-10 16:32:55 -05:00
parent db32337238
commit d4db2a2e9a
1 changed files with 1 additions and 0 deletions

View File

@ -70,6 +70,7 @@ getdns_general_sync(struct getdns_context *context,
{
getdns_return_t response_status;
RETURN_IF_NULL(context, GETDNS_RETURN_BAD_CONTEXT);
RETURN_IF_NULL(response, GETDNS_RETURN_INVALID_PARAMETER);
response_status = validate_extensions(extensions);
if (response_status == GETDNS_RETURN_GOOD) {
response_status = getdns_general_ub(context->unbound_sync,