From eef0f73620912a6a299a2558bd76e9454141c6cd Mon Sep 17 00:00:00 2001 From: Andreas Schneider Date: Thu, 10 Jun 2021 09:14:22 +0200 Subject: [PATCH] s3:smbd: Remove unnessesary NULL check for req MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit We already dereference req earlier. So if it is NULL it already segfaulted much earlier. Found by covscan. Signed-off-by: Andreas Schneider Reviewed-by: Pavel Filipenský Reviewed-by: Noel Power Autobuild-User(master): Noel Power Autobuild-Date(master): Thu Jun 10 11:22:19 UTC 2021 on sn-devel-184 --- source3/smbd/reply.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/source3/smbd/reply.c b/source3/smbd/reply.c index d453eb5e6f4..abec7857951 100644 --- a/source3/smbd/reply.c +++ b/source3/smbd/reply.c @@ -3572,7 +3572,7 @@ void reply_unlink(struct smb_request *req) goto out; } - if (req != NULL && !req->posix_pathnames) { + if (!req->posix_pathnames) { char *lcomp = get_original_lcomp(ctx, conn, name, -- 2.47.3