Eric Andersen | cc8ed39 | 1999-10-05 16:24:54 +0000 | [diff] [blame^] | 1 | #include "internal.h" |
2 | #include <errno.h> | ||||
3 | |||||
4 | const char rmdir_usage[] = "rmdir directory [directory ...]\n" | ||||
5 | "\n" | ||||
6 | "\tDelete directories.\n"; | ||||
7 | |||||
8 | extern int | ||||
9 | rmdir_fn(const struct FileInfo * i) | ||||
10 | { | ||||
11 | if ( rmdir(i->source) != 0 && errno != ENOENT && !i->force ) { | ||||
12 | name_and_error(i->source); | ||||
13 | return 1; | ||||
14 | } | ||||
15 | else | ||||
16 | return 0; | ||||
17 | } |