TALLOC_CTX *mem_ctx = talloc_tos();
uint8_t *inbuf;
- /* TODO: remove this hack */
- message_dispatch(smbd_messaging_context());
-
inbuf = (uint8_t *)talloc_memdup(mem_ctx, msg->buf.data,
msg->buf.length);
if (inbuf == NULL) {
to.tv_sec = SMBD_SELECT_TIMEOUT;
to.tv_usec = 0;
- /*
- * Note that this call must be before processing any SMB
- * messages as we need to synchronously process any messages
- * we may have sent to ourselves from the previous SMB.
- */
- message_dispatch(smbd_messaging_context());
-
/*
* Setup the select fd sets.
*/
return NT_STATUS_RETRY;
}
- /*
- * We've just woken up from a protentially long select sleep.
- * Ensure we process local messages as we need to synchronously
- * process any messages from other smbd's to avoid file rename race
- * conditions. This call is cheap if there are no messages waiting.
- * JRA.
- */
- message_dispatch(smbd_messaging_context());
-
- return NT_STATUS_OK;
+ /* should not be reached */
+ return NT_STATUS_INTERNAL_ERROR;
}
/*
TALLOC_CTX *mem_ctx = talloc_tos();
NTSTATUS status;
- /* TODO: remove this hack */
- message_dispatch(smbd_messaging_context());
-
/* TODO: make this completely nonblocking */
status = receive_smb_talloc(mem_ctx, smbd_server_fd(),