diff options
author | Jeremy Allison <jra@samba.org> | 2004-02-25 21:37:09 +0000 |
---|---|---|
committer | Jeremy Allison <jra@samba.org> | 2004-02-25 21:37:09 +0000 |
commit | 3f67bb3a69f7a1631e2e158f4d58095c88f6bbb2 (patch) | |
tree | 183dc53fea484dc1a496b25ff43a4d5ff2367b75 | |
parent | 4b6cb540de9dc04d3329062513895976f4214004 (diff) | |
download | samba-3f67bb3a69f7a1631e2e158f4d58095c88f6bbb2.tar.gz samba-3f67bb3a69f7a1631e2e158f4d58095c88f6bbb2.tar.bz2 samba-3f67bb3a69f7a1631e2e158f4d58095c88f6bbb2.zip |
Fixup strange rename error case (gentest).
Jeremy.
(This used to be commit e46aaffe97919afb1c92f56376f9578825012b92)
-rw-r--r-- | source3/smbd/reply.c | 3 |
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; } } |