diff options
author | Jeremy Allison <jra@samba.org> | 2004-02-24 01:45:56 +0000 |
---|---|---|
committer | Jeremy Allison <jra@samba.org> | 2004-02-24 01:45:56 +0000 |
commit | 4568c8bb228663c59b09d82fa5052b8eea32c465 (patch) | |
tree | e877ad0e05a7fc85bcfcc090f38dfb6f3d8a5488 /source3 | |
parent | fb11e4a874593eb8426150322dfc0e7181e7b949 (diff) | |
download | samba-4568c8bb228663c59b09d82fa5052b8eea32c465.tar.gz samba-4568c8bb228663c59b09d82fa5052b8eea32c465.tar.bz2 samba-4568c8bb228663c59b09d82fa5052b8eea32c465.zip |
Ensure '.' and '..' don't match in delete requests.
Jeremy.
(This used to be commit c85b617aa03c1524f659100030a8e96cef38fb62)
Diffstat (limited to 'source3')
-rw-r--r-- | source3/smbd/reply.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/source3/smbd/reply.c b/source3/smbd/reply.c index 26c107e17a..0fe3be0752 100644 --- a/source3/smbd/reply.c +++ b/source3/smbd/reply.c @@ -1449,7 +1449,10 @@ NTSTATUS unlink_internals(connection_struct *conn, int dirtype, char *name) while ((dname = ReadDirName(dirptr))) { pstring fname; pstrcpy(fname,dname); - + + if((strcmp(fname, ".") == 0) || (strcmp(fname, "..")==0)) + continue; + if(!mask_match(fname, mask, case_sensitive)) continue; |