3.2.4.1.3 RpcReplyClosePrinter (Opnum 60)
RpcReplyClosePrinter closes the notification channel between a print server and a print client.<415>
-
DWORD RpcReplyClosePrinter( [in, out] PRINTER_HANDLE* phNotify );
phNotify: A pointer to the notification context handle to close that was opened by RpcReplyOpenPrinter (section 3.2.4.1.1).
Return Values: This method MUST return zero (ERROR_SUCCESS) to indicate successful completion or a nonzero Windows error code to indicate failure [MS-ERREF].
Upon receiving this message, the client MUST validate parameters as follows:
Verify that the phNotify parameter is an RPC context handle to a notification object that was opened using RpcReplyOpenPrinter. If that verification fails, ERROR_INVALID_HANDLE MUST be returned. This method SHOULD assume that this handle can be used without further access checks.
If parameter validation fails, the client MUST fail the operation immediately and return a nonzero error response to the server. Otherwise, the client MUST process the message as follows:
Free the context handle associated with the notification state.
Return a response to the client containing the output parameters and the status of the operation.
If the operation is successful, the client MUST modify the notification state by removing the back channel context handle associated with it.