exit more nicely if command line arguments were wrong

This commit is contained in:
Christian Grothoff 2017-10-17 14:03:31 +02:00
parent fbc685a76c
commit e4fe0dc87e
No known key found for this signature in database
GPG Key ID: 939E6BE1E29FC3CC

View File

@ -1599,7 +1599,12 @@ main (int argc,
GNUNET_assert (COIN_VALUE <= (1LL << REFRESH_SLOTS_NEEDED)); GNUNET_assert (COIN_VALUE <= (1LL << REFRESH_SLOTS_NEEDED));
ret = GNUNET_GETOPT_run ("taler-exchange-benchmark", ret = GNUNET_GETOPT_run ("taler-exchange-benchmark",
options, argc, argv); options, argc, argv);
GNUNET_assert (GNUNET_SYSERR != ret); if (GNUNET_SYSERR == ret)
{
fprintf (stderr,
"Invalid command line arguments\n");
return 1;
}
if (GNUNET_NO == ret) if (GNUNET_NO == ret)
return 0; return 0;
if ( (0 != num_iterations) && if ( (0 != num_iterations) &&