From: Ralph Boehme Date: Tue, 7 Mar 2017 13:10:39 +0000 (+0100) Subject: s3/smbd: req is already validated at the beginning of open_file_ntcreate() X-Git-Tag: samba-4.4.11~12 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=a8db18aa97c5af73c1df5559e8c233469f033c7f;p=thirdparty%2Fsamba.git 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) --- 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); }