PeerDistUnregisterForStatusChangeNotification function (peerdist.h)

The PeerDistUnregisterForStatusChangeNotification function unregisters the status change notification for the session associated with the specified handle.

Syntax

DWORD PeerDistUnregisterForStatusChangeNotification(
  [in] PEERDIST_INSTANCE_HANDLE hPeerDist
);

Parameters

[in] hPeerDist

A PEERDIST_INSTANCE_HANDLE returned by PeerDistStartup.

Return value

If the function succeeds, the return value is ERROR_SUCCESS. Otherwise, the function may return one of the following values:

Return code Description
ERROR_INVALID_PARAMETER
One or more parameters are invalid.
ERROR_INVALID_HANDLE
The hPeerDist handle is invalid.

Remarks

This function cancels any registered notification previously set by a PeerDistRegisterForStatusChangeNotification function call.

To confirm successfully canceled operations, a call should be made to GetOverlappedResult using the OVERLAPPED structure returned by GetQueuedCompletionStatus with an expected return of FALSE.

Additionally, calling GetLastError immediately after a successful PeerDistRegisterForStatusChangeNotification will return the ERROR_OPERATION_ABORTED error code.

Requirements

Requirement Value
Minimum supported client Windows 7 Professional [desktop apps only]
Minimum supported server Windows Server 2008 R2 [desktop apps only]
Target Platform Windows
Header peerdist.h
Library PeerDist.lib
DLL PeerDist.dll

See also

PeerDistRegisterForStatusChangeNotification