summaryrefslogtreecommitdiff
path: root/src/benchmark/taler-exchange-benchmark.c
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2018-08-09 21:10:56 +0200
committerChristian Grothoff <christian@grothoff.org>2018-08-09 21:10:56 +0200
commitc51b19512bfc5bf3848211e6a4e9f3534ece7ee2 (patch)
tree46f5506ca113129e5a36897be25ca898a08c6866 /src/benchmark/taler-exchange-benchmark.c
parente3f7083b3eb39ed28eee27b6104a3a508437c929 (diff)
downloadexchange-c51b19512bfc5bf3848211e6a4e9f3534ece7ee2.tar.gz
exchange-c51b19512bfc5bf3848211e6a4e9f3534ece7ee2.tar.bz2
exchange-c51b19512bfc5bf3848211e6a4e9f3534ece7ee2.zip
report ore precisely where commands went wrong
Diffstat (limited to 'src/benchmark/taler-exchange-benchmark.c')
-rw-r--r--src/benchmark/taler-exchange-benchmark.c34
1 files changed, 18 insertions, 16 deletions
diff --git a/src/benchmark/taler-exchange-benchmark.c b/src/benchmark/taler-exchange-benchmark.c
index 342408d88..34777bbe7 100644
--- a/src/benchmark/taler-exchange-benchmark.c
+++ b/src/benchmark/taler-exchange-benchmark.c
@@ -741,21 +741,23 @@ main (int argc,
exchange_url);
GNUNET_free (exchange_url);
duration = GNUNET_TIME_absolute_get_duration (start_time);
-
- fprintf (stdout,
- "Executed (W=%u, D=%u, R~=%5.2f) * P=%u, operations in %s\n",
- howmany_coins,
- howmany_coins,
- (float) howmany_coins * REFRESH_PROBABILITY,
- howmany_clients,
- GNUNET_STRINGS_relative_time_to_string
- (duration,
- GNUNET_NO));
- fprintf (stdout,
- "(approximately %s/coin)\n",
- GNUNET_STRINGS_relative_time_to_string
- (GNUNET_TIME_relative_divide (duration,
- howmany_coins * howmany_clients),
- GNUNET_YES));
+ if (GNUNET_OK == result)
+ {
+ fprintf (stdout,
+ "Executed (W=%u, D=%u, R~=%5.2f) * P=%u, operations in %s\n",
+ howmany_coins,
+ howmany_coins,
+ (float) howmany_coins * REFRESH_PROBABILITY,
+ howmany_clients,
+ GNUNET_STRINGS_relative_time_to_string
+ (duration,
+ GNUNET_NO));
+ fprintf (stdout,
+ "(approximately %s/coin)\n",
+ GNUNET_STRINGS_relative_time_to_string
+ (GNUNET_TIME_relative_divide (duration,
+ howmany_coins * howmany_clients),
+ GNUNET_YES));
+ }
return (GNUNET_OK == result) ? 0 : result;
}