[SCM] Samba Shared Repository - branch master updated

Ralph Böhme slow at samba.org
Fri Feb 23 21:57:02 UTC 2018


The branch, master has been updated
       via  5ad5e79 s3: smbd: Fix possible directory fd leak if the underlying OS doesn't support fdopendir()
      from  06601b3 winbind: don't try to do an authenticated SMB connection as AD DC

https://git.samba.org/?p=samba.git;a=shortlog;h=master


- Log -----------------------------------------------------------------
commit 5ad5e7966f555b1d2b39d276646934a2cd2535e6
Author: Jeremy Allison <jra at samba.org>
Date:   Wed Feb 14 13:23:12 2018 -0800

    s3: smbd: Fix possible directory fd leak if the underlying OS doesn't support fdopendir()
    
    HPUX has this problem.
    
    BUG: https://bugzilla.samba.org/show_bug.cgi?id=13270
    
    Signed-off-by: Jeremy Allison <jra at samba.org>
    Reviewed-by: Ralph Boehme <slow at samba.org>
    
    Autobuild-User(master): Ralph Böhme <slow at samba.org>
    Autobuild-Date(master): Fri Feb 23 22:56:35 CET 2018 on sn-devel-144

-----------------------------------------------------------------------

Summary of changes:
 source3/smbd/smb2_query_directory.c | 9 ++++++---
 1 file changed, 6 insertions(+), 3 deletions(-)


Changeset truncated at 500 lines:

diff --git a/source3/smbd/smb2_query_directory.c b/source3/smbd/smb2_query_directory.c
index 430fdca..8884738 100644
--- a/source3/smbd/smb2_query_directory.c
+++ b/source3/smbd/smb2_query_directory.c
@@ -343,11 +343,14 @@ static struct tevent_req *smbd_smb2_query_directory_send(TALLOC_CTX *mem_ctx,
 	if (in_flags & SMB2_CONTINUE_FLAG_REOPEN) {
 		int flags;
 
-		dptr_CloseDir(fsp);
+		status = fd_close(fsp);
+		if (tevent_req_nterror(req, status)) {
+			return tevent_req_post(req, ev);
+		}
 
 		/*
-		 * dptr_CloseDir() will close and invalidate the fsp's file
-		 * descriptor, we have to reopen it.
+		 * fd_close() will close and invalidate the fsp's file
+		 * descriptor. So we have to reopen it.
 		 */
 
 		flags = O_RDONLY;


-- 
Samba Shared Repository



More information about the samba-cvs mailing list