Close (Opnum 12)

The Close method is received by the server in an RPC_REQUEST packet. In response, the server closes an open instance of the queue.

 HRESULT Close();

This method has no parameters.

Return Values: The method MUST return S_OK (0x00000000) on success or an implementation-specific error HRESULT on failure.

When processing this call, the server MUST follow these guidelines:

  • If the IsInitialized instance variable is False:

    • Return an error OLE_E_BLANK (0x80040007), and take no further action.

  • Remove the refQueue from the refQueue.OpenQueueDescriptor.

  • Set the OpenQueueDescriptor instance variable to NULL.

  • Set the IsClosed instance variable to True.

  • Return S_OK (0x00000000), and take no further action.