NDK_FN_CREATE_LISTENER callback function (ndkpi.h)
The NdkCreateListener (NDK_FN_CREATE_LISTENER) function creates an NDK listener object.
Syntax
NDK_FN_CREATE_LISTENER NdkFnCreateListener;
NTSTATUS NdkFnCreateListener(
[in] NDK_ADAPTER *pNdkAdapter,
[in] NDK_FN_CONNECT_EVENT_CALLBACK ConnectEvent,
[in, optional] PVOID ConnectEventContext,
[in] NDK_FN_CREATE_COMPLETION CreateCompletion,
[in, optional] PVOID RequestContext,
NDK_LISTENER **ppNdkListener
)
{...}
Parameters
[in] pNdkAdapter
A pointer to an NDK adapter object (NDK_ADAPTER).
[in] ConnectEvent
A pointer to the NdkConnectEventCallback function (NDK_FN_CONNECT_EVENT_CALLBACK) that the provider uses to notify the consumer for each incoming connection request.
[in, optional] ConnectEventContext
A context value that the NDK provider passes back to the NdkConnectEventCallback function that is specified in the ConnectEvent parameter.
[in] CreateCompletion
A pointer to an NdkCreateCompletion (NDK_FN_CREATE_COMPLETION) function that completes the creation of an NDK object.
[in, optional] RequestContext
A context value that the NDK provider passes back to the NdkCreateCompletion function that is specified in the CreateCompletion parameter.
ppNdkListener
A pointer to the created NDK listener object (NDK_LISTENER) is returned in this location if request succeeds without returning STATUS_PENDING. If NdkCreateListener returns STATUS_PENDING this parameter is ignored and the created object is returned with the callback that is specified in the CreateCompletion parameter.
Return value
The NdkCreateListener function returns one of the following NTSTATUS codes.
Return code | Description |
---|---|
|
The listener object was created successfully and returned with the *ppNdkListener parameter. |
|
The operation is pending and will be completed later. The provider will call the function specified in the CreateCompletion parameter(NDK_FN_CREATE_COMPLETION) to complete the pending operation. |
|
The request failed due to insufficient resources.
Important The request can fail inline as well as asynchronously with this status code.
|
|
An error occurred. |
Remarks
The NdkCreateListener function creates an NDK listener object. If the function returns STATUS_SUCCESS, the created object is returned in the ppNdkListener parameter. If NdkCreateListener returns STATUS_PENDING, the created object is returned by the NdkCreateCompletion (NDK_FN_CREATE_COMPLETION) function that is specified in the CreateCompletion parameter.
Requirements
Requirement | Value |
---|---|
Minimum supported client | None supported,Supported in NDIS 6.30 and later. |
Minimum supported server | Windows Server 2012 |
Target Platform | Windows |
Header | ndkpi.h (include Ndkpi.h) |
IRQL | <=DISPATCH_LEVEL |
See also
Feedback
https://aka.ms/ContentUserFeedback.
Coming soon: Throughout 2024 we will be phasing out GitHub Issues as the feedback mechanism for content and replacing it with a new feedback system. For more information see:Submit and view feedback for