[SCM] Samba Shared Repository - branch v3-3-test updated

Karolin Seeger kseeger at samba.org
Fri Oct 9 00:41:41 MDT 2009


The branch, v3-3-test has been updated
       via  1f604d2... Correct fix for bug 6781 - Cannot rename subfolders in Explorer view with recent versions of Samba. Without this fix, renaming a directory ./a to ./b, whilst a directory ./aa was already open would fail. Jeremy.
      from  fdc28f6... Fix bug 6769 - symlink unlink does nothing. Jeremy.

http://gitweb.samba.org/?p=samba.git;a=shortlog;h=v3-3-test


- Log -----------------------------------------------------------------
commit 1f604d26d038956a6ddde892610c9b2254268160
Author: Jeremy Allison <jra at samba.org>
Date:   Wed Oct 7 15:49:56 2009 -0700

    Correct fix for bug 6781 - Cannot rename subfolders in Explorer view with recent versions of Samba. Without this fix, renaming a directory ./a to ./b, whilst a directory ./aa was already open would fail. Jeremy.

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

Summary of changes:
 source/smbd/files.c |    9 +++++++--
 1 files changed, 7 insertions(+), 2 deletions(-)


Changeset truncated at 500 lines:

diff --git a/source/smbd/files.c b/source/smbd/files.c
index cdaa5f1..e74ad7a 100644
--- a/source/smbd/files.c
+++ b/source/smbd/files.c
@@ -407,13 +407,18 @@ bool file_find_subpath(files_struct *dir_fsp)
 					fsp->conn->connectpath,
 					fsp->fsp_name);
 
-		if (strnequal(d_fullname, d1_fullname, dlen)) {
+		/*
+		 * If the open file has a path that is a longer
+		 * component, then it's a subpath.
+		 */
+		if (strnequal(d_fullname, d1_fullname, dlen) &&
+				(d1_fullname[dlen] == '/')) {
 			TALLOC_FREE(d_fullname);
 			TALLOC_FREE(d1_fullname);
 			return true;
 		}
 		TALLOC_FREE(d1_fullname);
-	} 
+	}
 
 	TALLOC_FREE(d_fullname);
 	return false;


-- 
Samba Shared Repository


More information about the samba-cvs mailing list