diff options
author | Glenn L McGrath | 2004-01-23 21:40:19 +0000 |
---|---|---|
committer | Glenn L McGrath | 2004-01-23 21:40:19 +0000 |
commit | 654a99b691a5c031ad06eeba7cc554128551c7de (patch) | |
tree | 5342fb57aa65a81ffe0889bcb0760952a9d04dad | |
parent | 711bb92d7cd4cc00d3462414d85e3b15c6f2cd1b (diff) | |
download | busybox-654a99b691a5c031ad06eeba7cc554128551c7de.zip busybox-654a99b691a5c031ad06eeba7cc554128551c7de.tar.gz |
Check valid options were given
-rw-r--r-- | coreutils/install.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/coreutils/install.c b/coreutils/install.c index 3128c5b..84e60f9 100644 --- a/coreutils/install.c +++ b/coreutils/install.c @@ -54,8 +54,14 @@ extern int install_main(int argc, char **argv) int i; /* -c exists for backwards compatability, its needed */ + bb_opt_complementaly = "s~d:d~s"; flags = bb_getopt_ulflags(argc, argv, "cdpsg:m:o:", &gid_str, &mode_str, &uid_str); /* 'a' must be 2nd */ + /* Check valid options were given */ + if(flags & 0x80000000UL) { + bb_show_usage(); + } + /* preserve access and modification time, this is GNU behaviour, BSD only preserves modification time */ if (flags & INSTALL_OPT_PRESERVE_TIME) { copy_flags |= FILEUTILS_PRESERVE_STATUS; |