Use S_ISDIR() macro instead of a hand-rolled test.

This commit is contained in:
Yaroslav Tykhiy 2004-11-18 09:26:58 +00:00
parent b646893f0f
commit ac4f2391be

View File

@ -2490,7 +2490,7 @@ delete(char *name)
perror_reply(550, name);
return;
}
if ((st.st_mode&S_IFMT) == S_IFDIR) {
if (S_ISDIR(st.st_mode)) {
if (rmdir(name) < 0) {
perror_reply(550, name);
return;