chain to make it a little more readable.
printf (" \"%s\"\n", string[i]);
}
}
- else if (do_check == 0)
+ else if (do_check)
+ {
+ if (optind + 1 < argc)
+ {
+ error (0, 0,
+ _("only one argument may be specified when using --check"));
+ usage (EXIT_FAILURE);
+ }
+
+ err = md5_check ((optind == argc) ? "-" : argv[optind], binary);
+ }
+ else
{
if (optind == argc)
argv[argc++] = "-";
}
}
}
- else
- {
- if (optind + 1 < argc)
- {
- error (0, 0,
- _("only one argument may be specified when using --check"));
- usage (EXIT_FAILURE);
- }
-
- err = md5_check ((optind == argc) ? "-" : argv[optind], binary);
- }
if (fclose (stdout) == EOF)
error (EXIT_FAILURE, errno, _("write error"));