Skip to content

Commit

Permalink
only return query object when a query has been started
Browse files Browse the repository at this point in the history
  • Loading branch information
andreas-wehrmann committed Jun 17, 2024
1 parent 28c54a4 commit 6fe7629
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pjlib-util/src/pjlib-util/srv_resolver.c
Original file line number Diff line number Diff line change
Expand Up @@ -156,7 +156,7 @@ PJ_DEF(pj_status_t) pj_dns_srv_resolve( const pj_str_t *domain_name,
query_job->dns_state, 0,
&dns_callback,
query_job, &query_job->q_srv);
if (status==PJ_SUCCESS && p_query)
if (status==PJ_SUCCESS && p_query && query_job->q_srv)
*p_query = query_job;

return status;
Expand Down

0 comments on commit 6fe7629

Please sign in to comment.