From 99ce13a8bba4721f5c130cc7d8efa208a72bb6b1 Mon Sep 17 00:00:00 2001 From: Jeremy Allison Date: Mon, 19 Nov 2018 13:19:57 -0800 Subject: [PATCH] SQUASHME: Ensure cli_smb2_notify_send() doesn't time out to match SMB1 behavior. Signed-off-by: Jeremy Allison --- source3/libsmb/clifile.c | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/source3/libsmb/clifile.c b/source3/libsmb/clifile.c index 8de34ff2637..b50926307a5 100644 --- a/source3/libsmb/clifile.c +++ b/source3/libsmb/clifile.c @@ -5517,6 +5517,11 @@ struct tevent_req *cli_notify_send(TALLOC_CTX *mem_ctx, } if (smbXcli_conn_protocol(cli->conn) >= PROTOCOL_SMB2_02) { + /* + * Notifies should not time out + */ + old_timeout = cli_set_timeout(cli, 0); + state->subreq = cli_smb2_notify_send( state, ev, @@ -5525,6 +5530,9 @@ struct tevent_req *cli_notify_send(TALLOC_CTX *mem_ctx, buffer_size, completion_filter, recursive); + + cli_set_timeout(cli, old_timeout); + if (tevent_req_nomem(state->subreq, req)) { return tevent_req_post(req, ev); } -- 2.19.1.1215.g8438c0b245-goog