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 | |
parent | c11475c081afcd5ccc667451b9383510fd42cf1b (diff) |
removing dead code, using more named constants, checking return values better
Diffstat (limited to 'src/auditor')
-rw-r--r-- | src/auditor/taler-auditor-httpd.c | 2 | ||||
-rw-r--r-- | src/auditor/taler-auditor.c | 18 |
2 files changed, 10 insertions, 10 deletions
diff --git a/src/auditor/taler-auditor-httpd.c b/src/auditor/taler-auditor-httpd.c index 043d5b148..ff069f2aa 100644 --- a/src/auditor/taler-auditor-httpd.c +++ b/src/auditor/taler-auditor-httpd.c @@ -232,7 +232,7 @@ signal_loop (void) } if (EINTR == errno) { - ret = 2; + /* ignore, do the loop again */ continue; } switch (c) 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; |