Reject '--bitmap none' for build and create.

We don't want to create a file called 'none', and it isn't needed,
so just reject it.
This commit is contained in:
Neil Brown 2007-07-23 17:28:44 +10:00
parent 9bbcc5f7c4
commit 85375d6de1
1 changed files with 7 additions and 1 deletions

View File

@ -817,9 +817,15 @@ int main(int argc, char *argv[])
backup_file = optarg;
continue;
case O(GROW,'b'):
case O(BUILD,'b'):
case O(CREATE,'b'): /* here we create the bitmap */
if (strcmp(optarg, "none") == 0) {
fprintf(stderr, Name ": '--bitmap none' only"
" support for --grow\n");
exit(2);
}
/* FALL THROUGH */
case O(GROW,'b'):
if (strcmp(optarg, "internal")== 0 ||
strcmp(optarg, "none")== 0 ||
strchr(optarg, '/') != NULL) {