3.2.5.12 Receiving an SMB2 WRITE Response

If Connection.Dialect belongs to the SMB 3.x dialect family, the underlying transport is RDMA and Request.BufferDescriptorList is not empty, then the processing specified in [MS-SMBD] section 3.1.4.4 Deregister Buffer MUST be used to deregister the buffer before returning to the application.

If Connection.Dialect belongs to the SMB 3.x dialect family and the status code is STATUS_FILE_NOT_AVAILABLE, and Connection.ServerCapabilities includes SMB2_GLOBAL_CAP_PERSISTENT_HANDLES or SMB2_GLOBAL_CAP_MULTI_CHANNEL, the client MUST look up the request in Connection.OutstandingRequests using the MessageId field of the SMB2 header. If the request is found, the client SHOULD<186> replay the request by setting SMB2_FLAGS_REPLAY_OPERATION bit in the SMB2 header.

The client MUST return the received status code in the Status field of the SMB2 header of the response to the application that issued the request to write data to the file or named pipe. The client MUST also return the Count value from the SMB2 WRITE Response following the SMB2 header, indicating how many bytes were written.