diff options
author | Christian Grothoff <grothoff@gnunet.org> | 2022-03-31 02:54:42 +0200 |
---|---|---|
committer | Christian Grothoff <grothoff@gnunet.org> | 2022-03-31 02:54:42 +0200 |
commit | d88413f94d812552c1e76cfa6c2237fa9b318faf (patch) | |
tree | df498c877e393da771e71e007291439a76afeaf0 /src | |
parent | e184d373aaa78441d18d1a8eaf94d2edc4502868 (diff) | |
download | merchant-d88413f94d812552c1e76cfa6c2237fa9b318faf.tar.gz merchant-d88413f94d812552c1e76cfa6c2237fa9b318faf.tar.bz2 merchant-d88413f94d812552c1e76cfa6c2237fa9b318faf.zip |
fix failure to commit transaction bug reported by MS
Diffstat (limited to 'src')
-rw-r--r-- | src/backenddb/plugin_merchantdb_postgres.c | 14 |
1 files changed, 9 insertions, 5 deletions
diff --git a/src/backenddb/plugin_merchantdb_postgres.c b/src/backenddb/plugin_merchantdb_postgres.c index 39f42aef..d45e2fbb 100644 --- a/src/backenddb/plugin_merchantdb_postgres.c +++ b/src/backenddb/plugin_merchantdb_postgres.c @@ -5947,7 +5947,7 @@ RETRY: } if (GNUNET_OK != postgres_start (pg, - "enable tip reserve")) + "authorize tip")) { GNUNET_break (0); return TALER_EC_GENERIC_DB_START_FAILED; @@ -5981,7 +5981,13 @@ RETRY: break; } if (TALER_EC_NONE != lac.ec) + { + GNUNET_log (GNUNET_ERROR_TYPE_WARNING, + "Enabling tip reserved failed with status %d\n", + lac.ec); + postgres_rollback (pg); return lac.ec; + } GNUNET_assert (lac.ok); reserve_pubp = &lac.reserve_pub; } @@ -6015,8 +6021,7 @@ RETRY: { GNUNET_break (0); postgres_rollback (pg); - return - TALER_EC_GENERIC_DB_FETCH_FAILED; + return TALER_EC_GENERIC_DB_FETCH_FAILED; } if (0 == qs) { @@ -6068,8 +6073,7 @@ RETRY: { GNUNET_break (0); postgres_rollback (pg); - return - TALER_EC_GENERIC_DB_STORE_FAILED; + return TALER_EC_GENERIC_DB_STORE_FAILED; } } GNUNET_CRYPTO_random_block (GNUNET_CRYPTO_QUALITY_NONCE, |