summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJeremy Allison <jra@samba.org>2004-02-25 21:37:22 +0000
committerJeremy Allison <jra@samba.org>2004-02-25 21:37:22 +0000
commitfd6b9c02b91ea39e8c7575e1f5f106509940ba1f (patch)
tree241ccc67ba494d5a08dfec78e417866ff9c856c3
parentaf6f7254a9873a34fb391f1fd78aadadbc796063 (diff)
downloadsamba-fd6b9c02b91ea39e8c7575e1f5f106509940ba1f.tar.gz
samba-fd6b9c02b91ea39e8c7575e1f5f106509940ba1f.tar.bz2
samba-fd6b9c02b91ea39e8c7575e1f5f106509940ba1f.zip
Fixup strange rename error case (gentest).
Jeremy. (This used to be commit d448fb801e175e11cfc0118325043eef836103f0)
-rw-r--r--source3/smbd/reply.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/source3/smbd/reply.c b/source3/smbd/reply.c
index c729f22728..49f4e97028 100644
--- a/source3/smbd/reply.c
+++ b/source3/smbd/reply.c
@@ -3482,8 +3482,9 @@ NTSTATUS rename_internals(connection_struct *conn, char *name, char *newname, BO
unix_convert(newname,conn,newname_last_component,&bad_path2,&sbuf2);
/* Quick check for "." and ".." */
- if (newname_last_component[0] == '.') {
+ if (!bad_path2 && newname_last_component[0] == '.') {
if (!newname_last_component[1] || (newname_last_component[1] == '.' && !newname_last_component[2])) {
+ DEBUG(10,("rename_internals: newname_last_component = '.' or '..'\n"));
return NT_STATUS_ACCESS_DENIED;
}
}