From a8db18aa97c5af73c1df5559e8c233469f033c7f Mon Sep 17 00:00:00 2001 From: Ralph Boehme Date: Tue, 7 Mar 2017 14:10:39 +0100 Subject: [PATCH] s3/smbd: req is already validated at the beginning of open_file_ntcreate() req can't be NULL because the if condition surrounding this code checks !(oplock_request & INTERNAL_OPEN_ONLY). Bug: https://bugzilla.samba.org/show_bug.cgi?id=7537 Signed-off-by: Ralph Boehme Reviewed-by: Jeremy Allison (cherry picked from commit 8580adc1d968304b69237f289d13950972394b48) --- source3/smbd/open.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/source3/smbd/open.c b/source3/smbd/open.c index 9817569d4e7..2afe601f88f 100644 --- a/source3/smbd/open.c +++ b/source3/smbd/open.c @@ -3071,9 +3071,7 @@ static NTSTATUS open_file_ntcreate(connection_struct *conn, state.async_open = false; state.id = id; - if ((req != NULL) - && !request_timed_out(request_time, - timeout)) { + if (!request_timed_out(request_time, timeout)) { defer_open(lck, request_time, timeout, req, &state); } -- 2.47.2