]> git.ipfire.org Git - thirdparty/samba.git/commitdiff
s3/smbd: req is already validated at the beginning of open_file_ntcreate()
authorRalph Boehme <slow@samba.org>
Tue, 7 Mar 2017 13:10:39 +0000 (14:10 +0100)
committerKarolin Seeger <kseeger@samba.org>
Tue, 14 Mar 2017 11:49:24 +0000 (12:49 +0100)
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 <slow@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
(cherry picked from commit 8580adc1d968304b69237f289d13950972394b48)

source3/smbd/open.c

index 9817569d4e7e3f7d7957e2d30efba378565037db..2afe601f88fe1396b1f2fc96d57f5f6418ddadd5 100644 (file)
@@ -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);
                        }