DNS_QUERY_RAW_COMPLETION_ROUTINE callback function (windns.h)
Important
Some information relates to a prerelease product which may be substantially modified before it's commercially released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
DNS_QUERY_RAW_COMPLETION_ROUTINE is the function signature of an asynchronous callback function that you implement. The system calls your implementation with the results of a query that you initiated by calling DnsQueryRaw. The results contain both the parsed records and the raw result packet, to be passed on to later systems as desired. The result provides information about the server that provided the results.
The system calls this callback on query completion if DnsQueryRaw returns DNS_REQUEST_PENDING; and it will indicate the results of the query if successful, or any failures or cancellations.
Syntax
DNS_QUERY_RAW_COMPLETION_ROUTINE DnsQueryRawCompletionRoutine;
void DnsQueryRawCompletionRoutine(
VOID *queryContext,
DNS_QUERY_RAW_RESULT *queryResults
)
{...}
Parameters
queryContext
Type: _In_ VOID*
A pointer to the query context that was passed into DnsQueryRaw through the queryContext field of DNS_QUERY_RAW_REQUEST.
queryResults
Type: _Inout_ DNS_QUERY_RAW_RESULT*
A pointer to the results of the query. If this callback is made because of a query cancellation through DnsCancelQueryRaw, then the queryStatus field in queryResults will be set to ERROR_CANCELLED.
If it's not NULL
, then you must free the queryResults pointer by using DnsQueryRawResultFree.
Return value
None
Requirements
Requirement | Value |
---|---|
Target Platform | Windows |
Header | windns.h |