Disallow removing the "." entry. We do the same for ".." already and it seems

to be in line with what other systems do as well. Also fixes bug #3476.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29296 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Michael Lotz
2009-02-23 19:55:03 +00:00
parent f163ab92bb
commit 24a7f4c285
+1 -1
View File
@@ -5644,7 +5644,7 @@ dir_remove(int fd, char *path, bool kernel)
// "name/" -> "name", or "name/." -> "name"
lastSlash[0] = '\0';
}
} else if (!strcmp(path, ".."))
} else if (!strcmp(path, ".") || !strcmp(path, ".."))
return B_NOT_ALLOWED;
}