From 37bb6229ad48b7a443eefa19a1845ce92a5bf546 Mon Sep 17 00:00:00 2001 From: Ralph Boehme Date: Sun, 4 Aug 2019 09:29:44 +0200 Subject: [PATCH] s3: smbd: fix a comment in fd_close() Signed-off-by: Ralph Boehme Reviewed-by: Jeremy Allison --- source3/smbd/open.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/source3/smbd/open.c b/source3/smbd/open.c index 8fcd7b3b580..5ff83741dcd 100644 --- a/source3/smbd/open.c +++ b/source3/smbd/open.c @@ -833,7 +833,11 @@ NTSTATUS fd_close(files_struct *fsp) dptr_CloseDir(fsp); } if (fsp->fh->fd == -1) { - return NT_STATUS_OK; /* What we used to call a stat open. */ + /* + * Either a directory where the dptr_CloseDir() already closed + * the fd or a stat open. + */ + return NT_STATUS_OK; } if (fsp->fh->ref_count > 1) { return NT_STATUS_OK; /* Shared handle. Only close last reference. */ -- 2.47.3