mirror of
https://github.com/opnsense/src.git
synced 2026-06-11 01:30:30 -04:00
Backout rev. 1.42 (relaxing the check for -d plus other flags).
Instead, issue a warning for now if -d and -C options are used together. This will be turned into an error before 4.5-RELEASE. Reviewed by: imp
This commit is contained in:
parent
0bc62786ea
commit
fcbb2c69df
1 changed files with 8 additions and 1 deletions
|
|
@ -169,9 +169,16 @@ main(argc, argv)
|
|||
argv += optind;
|
||||
|
||||
/* some options make no sense when creating directories */
|
||||
if (dostrip && dodir)
|
||||
if ((safecopy || dostrip) && dodir)
|
||||
usage();
|
||||
|
||||
/*
|
||||
* Older versions allowed -d -C combo. Issue a warning
|
||||
* for now, but turn this into an error before 4.5-RELEASE.
|
||||
*/
|
||||
if (docompare && dodir)
|
||||
warnx("the -d and -C options may not be specified together");
|
||||
|
||||
/* must have at least two arguments, except when creating directories */
|
||||
if (argc < 2 && !dodir)
|
||||
usage();
|
||||
|
|
|
|||
Loading…
Reference in a new issue