From 8b94eb6cc8b0c63cf0787bd08ad469a72b0331c0 Mon Sep 17 00:00:00 2001 From: Stefan Metzmacher Date: Mon, 29 Jun 2009 15:38:48 +0200 Subject: s3:smbd: push nttrans and trans2 responses with no data to the client For sync replies it's not a problem, as construct_reply() will send the response, but for async replies we would not send the reply to the client. Currently the notify code works arround this manually, so I assume we didn't have a bug here. But the next commits will simplify the notify code. metze --- source3/smbd/nttrans.c | 8 ++++++++ source3/smbd/trans2.c | 8 ++++++++ 2 files changed, 16 insertions(+) (limited to 'source3') diff --git a/source3/smbd/nttrans.c b/source3/smbd/nttrans.c index a08414d0b0..368a1a8f98 100644 --- a/source3/smbd/nttrans.c +++ b/source3/smbd/nttrans.c @@ -74,6 +74,14 @@ void send_nt_replies(connection_struct *conn, __LINE__,__FILE__); } show_msg((char *)req->outbuf); + if (!srv_send_smb(smbd_server_fd(), + (char *)req->outbuf, + true, req->seqnum+1, + IS_CONN_ENCRYPTED(conn), + &req->pcd)) { + exit_server_cleanly("send_nt_replies: srv_send_smb failed."); + } + TALLOC_FREE(req->outbuf); return; } diff --git a/source3/smbd/trans2.c b/source3/smbd/trans2.c index 28b07527cc..ffa3de5af6 100644 --- a/source3/smbd/trans2.c +++ b/source3/smbd/trans2.c @@ -712,6 +712,14 @@ void send_trans2_replies(connection_struct *conn, if(params_to_send == 0 && data_to_send == 0) { reply_outbuf(req, 10, 0); show_msg((char *)req->outbuf); + if (!srv_send_smb(smbd_server_fd(), + (char *)req->outbuf, + true, req->seqnum+1, + IS_CONN_ENCRYPTED(conn), + &req->pcd)) { + exit_server_cleanly("send_trans2_replies: srv_send_smb failed."); + } + TALLOC_FREE(req->outbuf); return; } -- cgit