diff options
author | Christian Grothoff <christian@grothoff.org> | 2020-03-01 17:51:46 +0100 |
---|---|---|
committer | Christian Grothoff <christian@grothoff.org> | 2020-03-01 17:51:46 +0100 |
commit | 113f3891d13a15b87827a8b1b33508231a1409b7 (patch) | |
tree | 8b665c481282b0d3778deee534fd2b36b992608c /src/auditor/taler-auditor.c | |
parent | c11475c081afcd5ccc667451b9383510fd42cf1b (diff) |
removing dead code, using more named constants, checking return values better
Diffstat (limited to 'src/auditor/taler-auditor.c')
-rw-r--r-- | src/auditor/taler-auditor.c | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/src/auditor/taler-auditor.c b/src/auditor/taler-auditor.c index d211bd94a..2d33987b3 100644 --- a/src/auditor/taler-auditor.c +++ b/src/auditor/taler-auditor.c @@ -772,7 +772,7 @@ get_denomination_info_by_hash (const struct GNUNET_HashCode *dh, NULL); if (qs <= 0) { - if (0 == qs) + if (GNUNET_DB_STATUS_SUCCESS_NO_RESULTS == qs) GNUNET_log (GNUNET_ERROR_TYPE_INFO, "Denomination %s not found\n", TALER_B2S (dh)); @@ -3774,10 +3774,10 @@ refresh_session_cb (void *cls, cc->qs = qs; return GNUNET_SYSERR; } - if (GNUNET_DB_STATUS_SUCCESS_ONE_RESULT != - check_known_coin (coin_pub, - denom_pub, - amount_with_fee)) + qs = check_known_coin (coin_pub, + denom_pub, + amount_with_fee); + if (GNUNET_DB_STATUS_SUCCESS_ONE_RESULT != qs) { GNUNET_break (GNUNET_DB_STATUS_SOFT_ERROR == qs); cc->qs = qs; @@ -4152,10 +4152,10 @@ deposit_cb (void *cls, cc->qs = qs; return GNUNET_SYSERR; } - if (GNUNET_DB_STATUS_SUCCESS_ONE_RESULT != - check_known_coin (coin_pub, - denom_pub, - amount_with_fee)) + qs = check_known_coin (coin_pub, + denom_pub, + amount_with_fee); + if (GNUNET_DB_STATUS_SUCCESS_ONE_RESULT != qs) { GNUNET_break (GNUNET_DB_STATUS_SOFT_ERROR == qs); cc->qs = qs; |