Fix invocation without arguments

Closes #29
This commit is contained in:
Michal Trojnara 2020-01-25 18:41:47 +01:00
parent 7366df707d
commit 2bb573219a

View File

@ -3068,6 +3068,7 @@ int main(int argc, char **argv) {
md = EVP_sha1(); md = EVP_sha1();
if (argc > 1) {
if (!strcmp(argv[1], "--help")) { if (!strcmp(argv[1], "--help")) {
printf(PACKAGE_STRING ", using:\n\t%s\n\t%s\n\n", printf(PACKAGE_STRING ", using:\n\t%s\n\t%s\n\n",
SSLeay_version(SSLEAY_VERSION), SSLeay_version(SSLEAY_VERSION),
@ -3078,10 +3079,7 @@ int main(int argc, char **argv) {
#endif #endif
); );
help_for(argv0, "all"); help_for(argv0, "all");
} } else if (!strcmp(argv[1], "sign")) {
if (argc > 1) {
if (!strcmp(argv[1], "sign")) {
cmd = CMD_SIGN; cmd = CMD_SIGN;
argv++; argv++;
argc--; argc--;