summaryrefslogtreecommitdiff
path: root/src/auditordb
diff options
context:
space:
mode:
Diffstat (limited to 'src/auditordb')
-rw-r--r--src/auditordb/pg_get_amount_arithmetic_inconsistency.c45
-rw-r--r--src/auditordb/pg_get_auditor_closure_lags.c45
-rw-r--r--src/auditordb/pg_get_coin_inconsistency.c47
-rw-r--r--src/auditordb/pg_get_denomination_key_validity_withdraw_inconsistency.c43
-rw-r--r--src/auditordb/pg_get_denomination_pending.c55
-rw-r--r--src/auditordb/pg_get_denominations_without_sigs.c46
-rw-r--r--src/auditordb/pg_get_exchange_signkeys.c48
-rw-r--r--src/auditordb/pg_get_fee_time_inconsistency.c43
-rw-r--r--src/auditordb/pg_get_historic_denomination_revenue.c43
-rw-r--r--src/auditordb/pg_get_historic_reserve_summary.c36
-rw-r--r--src/auditordb/pg_get_misattribution_in_inconsistency.c40
-rw-r--r--src/auditordb/pg_get_purse_not_closed_inconsistencies.c43
-rw-r--r--src/auditordb/pg_get_purses.c43
-rw-r--r--src/auditordb/pg_get_refreshes_hanging.c40
-rw-r--r--src/auditordb/pg_get_reserve_balance_insufficient_inconsistency.c43
-rw-r--r--src/auditordb/pg_get_reserve_balance_summary_wrong_inconsistency.c43
-rw-r--r--src/auditordb/pg_get_reserve_in_inconsistency.c59
-rw-r--r--src/auditordb/pg_get_reserve_not_closed_inconsistency.c49
-rw-r--r--src/auditordb/pg_get_reserves.c81
-rw-r--r--src/auditordb/pg_get_row_inconsistency.c41
-rw-r--r--src/auditordb/pg_get_row_minor_inconsistencies.c34
-rw-r--r--src/auditordb/pg_get_wire_format_inconsistency.c40
-rw-r--r--src/auditordb/pg_get_wire_out_inconsistency.c41
-rw-r--r--src/auditordb/pg_insert_denomination_pending.c33
-rw-r--r--src/auditordb/pg_insert_denominations_without_sigs.c27
-rw-r--r--src/auditordb/pg_insert_exchange_signkeys.c29
-rw-r--r--src/auditordb/pg_insert_historic_denomination_revenue.c25
-rw-r--r--src/auditordb/pg_insert_historic_reserve_summary.c21
-rw-r--r--src/auditordb/pg_insert_misattribution_in_inconsistency.c23
-rw-r--r--src/auditordb/pg_insert_purses.c29
-rw-r--r--src/auditordb/pg_insert_reserve_in_inconsistency.c35
-rw-r--r--src/auditordb/pg_insert_reserve_not_closed_inconsistency.c27
-rw-r--r--src/auditordb/pg_insert_reserves.c53
-rw-r--r--src/auditordb/pg_insert_row_minor_inconsistencies.c19
-rw-r--r--src/auditordb/pg_insert_wire_format_inconsistency.c23
-rw-r--r--src/auditordb/pg_insert_wire_out_inconsistency.c23
36 files changed, 663 insertions, 752 deletions
diff --git a/src/auditordb/pg_get_amount_arithmetic_inconsistency.c b/src/auditordb/pg_get_amount_arithmetic_inconsistency.c
index 312d9e233..a23fa40bd 100644
--- a/src/auditordb/pg_get_amount_arithmetic_inconsistency.c
+++ b/src/auditordb/pg_get_amount_arithmetic_inconsistency.c
@@ -111,12 +111,12 @@ TAH_PG_get_amount_arithmetic_inconsistency (
struct PostgresClosure *pg = cls;
- struct GNUNET_PQ_QueryParam params[] = {
- GNUNET_PQ_query_param_uint64 (&offset),
- GNUNET_PQ_query_param_bool (return_suppressed),
- GNUNET_PQ_query_param_int64 (&limit),
- GNUNET_PQ_query_param_end
- };
+ struct GNUNET_PQ_QueryParam params[] = {
+ GNUNET_PQ_query_param_uint64 (&offset),
+ GNUNET_PQ_query_param_bool (return_suppressed),
+ GNUNET_PQ_query_param_int64 (&limit),
+ GNUNET_PQ_query_param_end
+ };
struct AmountArithmeticInconsistencyContext dcc = {
.cb = cb,
.cb_cls = cb_cls,
@@ -138,22 +138,25 @@ TAH_PG_get_amount_arithmetic_inconsistency (
" ORDER BY row_id DESC"
" LIMIT $3"
);
- PREPARE (pg,
- "auditor_amount_arithmetic_inconsistency_select_asc",
- "SELECT"
- " row_id"
- ",operation"
- ",exchange_amount"
- ",auditor_amount"
- ",profitable"
- " FROM auditor_amount_arithmetic_inconsistency"
- " WHERE (row_id>$1)"
- " AND ($2 OR suppressed is false)"
- " ORDER BY row_id ASC"
- " LIMIT $3"
- );
+ PREPARE (pg,
+ "auditor_amount_arithmetic_inconsistency_select_asc",
+ "SELECT"
+ " row_id"
+ ",operation"
+ ",exchange_amount"
+ ",auditor_amount"
+ ",profitable"
+ " FROM auditor_amount_arithmetic_inconsistency"
+ " WHERE (row_id>$1)"
+ " AND ($2 OR suppressed is false)"
+ " ORDER BY row_id ASC"
+ " LIMIT $3"
+ );
qs = GNUNET_PQ_eval_prepared_multi_select (pg->conn,
- (limit > 0) ? "auditor_amount_arithmetic_inconsistency_select_asc" : "auditor_amount_arithmetic_inconsistency_select_desc",
+ (limit > 0) ?
+ "auditor_amount_arithmetic_inconsistency_select_asc"
+ :
+ "auditor_amount_arithmetic_inconsistency_select_desc",
params,
&amount_arithmetic_inconsistency_cb,
&dcc);
diff --git a/src/auditordb/pg_get_auditor_closure_lags.c b/src/auditordb/pg_get_auditor_closure_lags.c
index 409be8a9b..0cf9bcf72 100644
--- a/src/auditordb/pg_get_auditor_closure_lags.c
+++ b/src/auditordb/pg_get_auditor_closure_lags.c
@@ -104,12 +104,12 @@ TAH_PG_get_auditor_closure_lags (
{
struct PostgresClosure *pg = cls;
- struct GNUNET_PQ_QueryParam params[] = {
- GNUNET_PQ_query_param_uint64 (&offset),
- GNUNET_PQ_query_param_bool (return_suppressed),
- GNUNET_PQ_query_param_int64 (&limit),
- GNUNET_PQ_query_param_end
- };
+ struct GNUNET_PQ_QueryParam params[] = {
+ GNUNET_PQ_query_param_uint64 (&offset),
+ GNUNET_PQ_query_param_bool (return_suppressed),
+ GNUNET_PQ_query_param_int64 (&limit),
+ GNUNET_PQ_query_param_end
+ };
struct ClosureLagsContext dcc = {
.cb = cb,
@@ -132,22 +132,25 @@ TAH_PG_get_auditor_closure_lags (
" ORDER BY row_id DESC"
" LIMIT $3"
);
- PREPARE (pg,
- "auditor_closure_lags_get_asc",
- "SELECT"
- " row_id"
- ",amount"
- ",deadline"
- ",wtid"
- ",account"
- " FROM auditor_closure_lags"
- " WHERE (row_id > $1)"
- " AND ($2 OR suppressed is false)"
- " ORDER BY row_id ASC"
- " LIMIT $3"
- );
+ PREPARE (pg,
+ "auditor_closure_lags_get_asc",
+ "SELECT"
+ " row_id"
+ ",amount"
+ ",deadline"
+ ",wtid"
+ ",account"
+ " FROM auditor_closure_lags"
+ " WHERE (row_id > $1)"
+ " AND ($2 OR suppressed is false)"
+ " ORDER BY row_id ASC"
+ " LIMIT $3"
+ );
qs = GNUNET_PQ_eval_prepared_multi_select (pg->conn,
- (limit > 0) ? "auditor_auditor_closure_lags_get_asc" : "auditor_auditor_closure_lags_get_desc",
+ (limit > 0) ?
+ "auditor_auditor_closure_lags_get_asc"
+ :
+ "auditor_auditor_closure_lags_get_desc",
params,
&closure_lags_cb,
&dcc);
diff --git a/src/auditordb/pg_get_coin_inconsistency.c b/src/auditordb/pg_get_coin_inconsistency.c
index 0e6c45a18..c29d386db 100644
--- a/src/auditordb/pg_get_coin_inconsistency.c
+++ b/src/auditordb/pg_get_coin_inconsistency.c
@@ -115,12 +115,12 @@ TAH_PG_get_coin_inconsistency (
printf ("checkpoint pg_0\n");
struct PostgresClosure *pg = cls;
- struct GNUNET_PQ_QueryParam params[] = {
- GNUNET_PQ_query_param_uint64 (&offset),
- GNUNET_PQ_query_param_bool (return_suppressed),
- GNUNET_PQ_query_param_int64 (&limit),
- GNUNET_PQ_query_param_end
- };
+ struct GNUNET_PQ_QueryParam params[] = {
+ GNUNET_PQ_query_param_uint64 (&offset),
+ GNUNET_PQ_query_param_bool (return_suppressed),
+ GNUNET_PQ_query_param_int64 (&limit),
+ GNUNET_PQ_query_param_end
+ };
struct CoinInconsistencyContext dcc = {
.cb = cb,
.cb_cls = cb_cls,
@@ -145,23 +145,26 @@ TAH_PG_get_coin_inconsistency (
" ORDER BY row_id DESC"
" LIMIT $3"
);
- PREPARE (pg,
- "auditor_coin_inconsistency_select_asc",
- "SELECT"
- " row_id"
- ",operation"
- ",exchange_amount"
- ",auditor_amount"
- ",coin_pub"
- ",profitable"
- " FROM auditor_coin_inconsistency"
- " WHERE (row_id > $1)"
- " AND ($2 OR suppressed is false)"
- " ORDER BY row_id ASC"
- " LIMIT $3"
- );
+ PREPARE (pg,
+ "auditor_coin_inconsistency_select_asc",
+ "SELECT"
+ " row_id"
+ ",operation"
+ ",exchange_amount"
+ ",auditor_amount"
+ ",coin_pub"
+ ",profitable"
+ " FROM auditor_coin_inconsistency"
+ " WHERE (row_id > $1)"
+ " AND ($2 OR suppressed is false)"
+ " ORDER BY row_id ASC"
+ " LIMIT $3"
+ );
qs = GNUNET_PQ_eval_prepared_multi_select (pg->conn,
- (limit > 0) ? "auditor_coin_inconsistency_select_asc" : "auditor_coin_inconsistency_select_desc",
+ (limit > 0) ?
+ "auditor_coin_inconsistency_select_asc"
+ :
+ "auditor_coin_inconsistency_select_desc",
params,
&coin_inconsistency_cb,
&dcc);
diff --git a/src/auditordb/pg_get_denomination_key_validity_withdraw_inconsistency.c b/src/auditordb/pg_get_denomination_key_validity_withdraw_inconsistency.c
index 94537b151..345384e11 100644
--- a/src/auditordb/pg_get_denomination_key_validity_withdraw_inconsistency.c
+++ b/src/auditordb/pg_get_denomination_key_validity_withdraw_inconsistency.c
@@ -106,12 +106,12 @@ TAH_PG_get_denomination_key_validity_withdraw_inconsistency (
{
struct PostgresClosure *pg = cls;
- struct GNUNET_PQ_QueryParam params[] = {
- GNUNET_PQ_query_param_uint64 (&offset),
- GNUNET_PQ_query_param_bool (return_suppressed),
- GNUNET_PQ_query_param_int64 (&limit),
- GNUNET_PQ_query_param_end
- };
+ struct GNUNET_PQ_QueryParam params[] = {
+ GNUNET_PQ_query_param_uint64 (&offset),
+ GNUNET_PQ_query_param_bool (return_suppressed),
+ GNUNET_PQ_query_param_int64 (&limit),
+ GNUNET_PQ_query_param_end
+ };
struct DenominationKeyValidityWithdrawInconsistencyContext dcc = {
.cb = cb,
.cb_cls = cb_cls,
@@ -132,21 +132,24 @@ TAH_PG_get_denomination_key_validity_withdraw_inconsistency (
" ORDER BY row_id DESC"
" LIMIT $3"
);
- PREPARE (pg,
- "auditor_denomination_key_validity_withdraw_inconsistency_get_asc",
- "SELECT"
- " row_id"
- ",execution_date"
- ",reserve_pub"
- ",denompub_h"
- " FROM auditor_denomination_key_validity_withdraw_inconsistency"
- " WHERE (row_id > $1)"
- " AND ($2 OR suppressed is false)"
- " ORDER BY row_id ASC"
- " LIMIT $3"
- );
+ PREPARE (pg,
+ "auditor_denomination_key_validity_withdraw_inconsistency_get_asc",
+ "SELECT"
+ " row_id"
+ ",execution_date"
+ ",reserve_pub"
+ ",denompub_h"
+ " FROM auditor_denomination_key_validity_withdraw_inconsistency"
+ " WHERE (row_id > $1)"
+ " AND ($2 OR suppressed is false)"
+ " ORDER BY row_id ASC"
+ " LIMIT $3"
+ );
qs = GNUNET_PQ_eval_prepared_multi_select (pg->conn,
- (limit > 0 ) ? "auditor_denomination_key_validity_withdraw_inconsistency_get_asc" : "auditor_denomination_key_validity_withdraw_inconsistency_get_desc",
+ (limit > 0) ?
+ "auditor_denomination_key_validity_withdraw_inconsistency_get_asc"
+ :
+ "auditor_denomination_key_validity_withdraw_inconsistency_get_desc",
params,
&
denomination_key_validity_withdraw_inconsistency_cb,
diff --git a/src/auditordb/pg_get_denomination_pending.c b/src/auditordb/pg_get_denomination_pending.c
index e7b82fe9b..975034189 100644
--- a/src/auditordb/pg_get_denomination_pending.c
+++ b/src/auditordb/pg_get_denomination_pending.c
@@ -1,6 +1,3 @@
-
-
-
/*
This file is part of TALER
Copyright (C) 2024 Taler Systems SA
@@ -63,8 +60,8 @@ struct DenominationPendingContext
*/
static void
denomination_pending_cb (void *cls,
- PGresult *result,
- unsigned int num_results)
+ PGresult *result,
+ unsigned int num_results)
{
struct DenominationPendingContext *dcc = cls;
struct PostgresClosure *pg = dcc->pg;
@@ -79,13 +76,14 @@ denomination_pending_cb (void *cls,
GNUNET_PQ_result_spec_uint64 ("row_id", &serial_id),
- GNUNET_PQ_result_spec_auto_from_type("denom_pub_hash", &dc.denom_pub_hash),
-TALER_PQ_RESULT_SPEC_AMOUNT("denom_balance", &dc.denom_balance),
-TALER_PQ_RESULT_SPEC_AMOUNT("denom_loss", &dc.denom_loss),
-GNUNET_PQ_result_spec_int64("num_issued", &dc.num_issued),
-TALER_PQ_RESULT_SPEC_AMOUNT("denom_risk", &dc.denom_risk),
-TALER_PQ_RESULT_SPEC_AMOUNT("recoup_loss", &dc.recoup_loss),
-GNUNET_PQ_result_spec_bool("suppressed", &dc.suppressed),
+ GNUNET_PQ_result_spec_auto_from_type ("denom_pub_hash",
+ &dc.denom_pub_hash),
+ TALER_PQ_RESULT_SPEC_AMOUNT ("denom_balance", &dc.denom_balance),
+ TALER_PQ_RESULT_SPEC_AMOUNT ("denom_loss", &dc.denom_loss),
+ GNUNET_PQ_result_spec_int64 ("num_issued", &dc.num_issued),
+ TALER_PQ_RESULT_SPEC_AMOUNT ("denom_risk", &dc.denom_risk),
+ TALER_PQ_RESULT_SPEC_AMOUNT ("recoup_loss", &dc.recoup_loss),
+ GNUNET_PQ_result_spec_bool ("suppressed", &dc.suppressed),
GNUNET_PQ_result_spec_end
@@ -142,12 +140,12 @@ TAH_PG_get_denomination_pending (
"auditor_denomination_pending_get_desc",
"SELECT"
" denom_pub_hash,"
-" denom_balance,"
-" denom_loss,"
-" num_issued,"
-" denom_risk,"
-" recoup_loss,"
-" suppressed"
+ " denom_balance,"
+ " denom_loss,"
+ " num_issued,"
+ " denom_risk,"
+ " recoup_loss,"
+ " suppressed"
" FROM auditor_denomination_pending"
" WHERE (row_id < $1)"
" AND ($2 OR suppressed is false)"
@@ -158,12 +156,12 @@ TAH_PG_get_denomination_pending (
"auditor_denomination_pending_get_asc",
"SELECT"
" denom_pub_hash,"
-" denom_balance,"
-" denom_loss,"
-" num_issued,"
-" denom_risk,"
-" recoup_loss,"
-" suppressed"
+ " denom_balance,"
+ " denom_loss,"
+ " num_issued,"
+ " denom_risk,"
+ " recoup_loss,"
+ " suppressed"
" FROM auditor_denomination_pending"
" WHERE (row_id > $1)"
" AND ($2 OR suppressed is false)"
@@ -172,8 +170,10 @@ TAH_PG_get_denomination_pending (
);
qs = GNUNET_PQ_eval_prepared_multi_select (pg->conn,
(limit > 0)
- ? "auditor_denomination_pending_get_asc"
- : "auditor_denomination_pending_get_desc",
+ ?
+ "auditor_denomination_pending_get_asc"
+ :
+ "auditor_denomination_pending_get_desc",
params,
&denomination_pending_cb,
&dcc);
@@ -183,6 +183,3 @@ TAH_PG_get_denomination_pending (
GNUNET_break (GNUNET_DB_STATUS_HARD_ERROR != qs);
return qs;
}
-
-
- \ No newline at end of file
diff --git a/src/auditordb/pg_get_denominations_without_sigs.c b/src/auditordb/pg_get_denominations_without_sigs.c
index 227c00d45..c19d704aa 100644
--- a/src/auditordb/pg_get_denominations_without_sigs.c
+++ b/src/auditordb/pg_get_denominations_without_sigs.c
@@ -1,6 +1,3 @@
-
-
-
/*
This file is part of TALER
Copyright (C) 2024 Taler Systems SA
@@ -63,8 +60,8 @@ struct DenominationsWithoutSigsContext
*/
static void
denominations_without_sigs_cb (void *cls,
- PGresult *result,
- unsigned int num_results)
+ PGresult *result,
+ unsigned int num_results)
{
struct DenominationsWithoutSigsContext *dcc = cls;
struct PostgresClosure *pg = dcc->pg;
@@ -79,11 +76,11 @@ denominations_without_sigs_cb (void *cls,
GNUNET_PQ_result_spec_uint64 ("row_id", &serial_id),
- GNUNET_PQ_result_spec_auto_from_type("denompub_h", &dc.denompub_h),
-TALER_PQ_RESULT_SPEC_AMOUNT("value", &dc.value),
-GNUNET_PQ_result_spec_int64("start_time", &dc.start_time),
-GNUNET_PQ_result_spec_int64("end_time", &dc.end_time),
-GNUNET_PQ_result_spec_bool("suppressed", &dc.suppressed),
+ GNUNET_PQ_result_spec_auto_from_type ("denompub_h", &dc.denompub_h),
+ TALER_PQ_RESULT_SPEC_AMOUNT ("value", &dc.value),
+ GNUNET_PQ_result_spec_int64 ("start_time", &dc.start_time),
+ GNUNET_PQ_result_spec_int64 ("end_time", &dc.end_time),
+ GNUNET_PQ_result_spec_bool ("suppressed", &dc.suppressed),
GNUNET_PQ_result_spec_end
@@ -140,11 +137,11 @@ TAH_PG_get_denominations_without_sigs (
"auditor_denominations_without_sigs_get_desc",
"SELECT"
" row_id,"
-" denompub_h,"
-" value,"
-" start_time,"
-" end_time,"
-" suppressed"
+ " denompub_h,"
+ " value,"
+ " start_time,"
+ " end_time,"
+ " suppressed"
" FROM auditor_denominations_without_sigs"
" WHERE (row_id < $1)"
" AND ($2 OR suppressed is false)"
@@ -155,11 +152,11 @@ TAH_PG_get_denominations_without_sigs (
"auditor_denominations_without_sigs_get_asc",
"SELECT"
" row_id,"
-" denompub_h,"
-" value,"
-" start_time,"
-" end_time,"
-" suppressed"
+ " denompub_h,"
+ " value,"
+ " start_time,"
+ " end_time,"
+ " suppressed"
" FROM auditor_denominations_without_sigs"
" WHERE (row_id > $1)"
" AND ($2 OR suppressed is false)"
@@ -168,8 +165,10 @@ TAH_PG_get_denominations_without_sigs (
);
qs = GNUNET_PQ_eval_prepared_multi_select (pg->conn,
(limit > 0)
- ? "auditor_denominations_without_sigs_get_asc"
- : "auditor_denominations_without_sigs_get_desc",
+ ?
+ "auditor_denominations_without_sigs_get_asc"
+ :
+ "auditor_denominations_without_sigs_get_desc",
params,
&denominations_without_sigs_cb,
&dcc);
@@ -179,6 +178,3 @@ TAH_PG_get_denominations_without_sigs (
GNUNET_break (GNUNET_DB_STATUS_HARD_ERROR != qs);
return qs;
}
-
-
- \ No newline at end of file
diff --git a/src/auditordb/pg_get_exchange_signkeys.c b/src/auditordb/pg_get_exchange_signkeys.c
index 0d0ee64dd..96d2d2917 100644
--- a/src/auditordb/pg_get_exchange_signkeys.c
+++ b/src/auditordb/pg_get_exchange_signkeys.c
@@ -1,6 +1,3 @@
-
-
-
/*
This file is part of TALER
Copyright (C) 2024 Taler Systems SA
@@ -63,8 +60,8 @@ struct ExchangeSignkeysContext
*/
static void
exchange_signkeys_cb (void *cls,
- PGresult *result,
- unsigned int num_results)
+ PGresult *result,
+ unsigned int num_results)
{
struct ExchangeSignkeysContext *dcc = cls;
struct PostgresClosure *pg = dcc->pg;
@@ -79,12 +76,12 @@ exchange_signkeys_cb (void *cls,
GNUNET_PQ_result_spec_uint64 ("row_id", &serial_id),
- GNUNET_PQ_result_spec_auto_from_type("exchange_pub", &dc.exchange_pub),
-GNUNET_PQ_result_spec_auto_from_type("master_sig", &dc.master_sig),
-GNUNET_PQ_result_spec_int64("ep_valid_from", &dc.ep_valid_from),
-GNUNET_PQ_result_spec_int64("ep_expire_sign", &dc.ep_expire_sign),
-GNUNET_PQ_result_spec_int64("ep_expire_legal", &dc.ep_expire_legal),
-GNUNET_PQ_result_spec_bool("suppressed", &dc.suppressed),
+ GNUNET_PQ_result_spec_auto_from_type ("exchange_pub", &dc.exchange_pub),
+ GNUNET_PQ_result_spec_auto_from_type ("master_sig", &dc.master_sig),
+ GNUNET_PQ_result_spec_int64 ("ep_valid_from", &dc.ep_valid_from),
+ GNUNET_PQ_result_spec_int64 ("ep_expire_sign", &dc.ep_expire_sign),
+ GNUNET_PQ_result_spec_int64 ("ep_expire_legal", &dc.ep_expire_legal),
+ GNUNET_PQ_result_spec_bool ("suppressed", &dc.suppressed),
GNUNET_PQ_result_spec_end
@@ -141,11 +138,11 @@ TAH_PG_get_exchange_signkeys (
"auditor_exchange_signkeys_get_desc",
"SELECT"
" exchange_pub,"
-" master_sig,"
-" ep_valid_from,"
-" ep_expire_sign,"
-" ep_expire_legal,"
-" suppressed"
+ " master_sig,"
+ " ep_valid_from,"
+ " ep_expire_sign,"
+ " ep_expire_legal,"
+ " suppressed"
" FROM auditor_exchange_signkeys"
" WHERE (row_id < $1)"
" AND ($2 OR suppressed is false)"
@@ -156,11 +153,11 @@ TAH_PG_get_exchange_signkeys (
"auditor_exchange_signkeys_get_asc",
"SELECT"
" exchange_pub,"
-" master_sig,"
-" ep_valid_from,"
-" ep_expire_sign,"
-" ep_expire_legal,"
-" suppressed"
+ " master_sig,"
+ " ep_valid_from,"
+ " ep_expire_sign,"
+ " ep_expire_legal,"
+ " suppressed"
" FROM auditor_exchange_signkeys"
" WHERE (row_id > $1)"
" AND ($2 OR suppressed is false)"
@@ -169,8 +166,10 @@ TAH_PG_get_exchange_signkeys (
);
qs = GNUNET_PQ_eval_prepared_multi_select (pg->conn,
(limit > 0)
- ? "auditor_exchange_signkeys_get_asc"
- : "auditor_exchange_signkeys_get_desc",
+ ?
+ "auditor_exchange_signkeys_get_asc"
+ :
+ "auditor_exchange_signkeys_get_desc",
params,
&exchange_signkeys_cb,
&dcc);
@@ -180,6 +179,3 @@ TAH_PG_get_exchange_signkeys (
GNUNET_break (GNUNET_DB_STATUS_HARD_ERROR != qs);
return qs;
}
-
-
- \ No newline at end of file
diff --git a/src/auditordb/pg_get_fee_time_inconsistency.c b/src/auditordb/pg_get_fee_time_inconsistency.c
index 5b1a7aa3f..e63dddfab 100644
--- a/src/auditordb/pg_get_fee_time_inconsistency.c
+++ b/src/auditordb/pg_get_fee_time_inconsistency.c
@@ -107,12 +107,12 @@ TAH_PG_get_fee_time_inconsistency (
{
struct PostgresClosure *pg = cls;
- struct GNUNET_PQ_QueryParam params[] = {
- GNUNET_PQ_query_param_uint64 (&offset),
- GNUNET_PQ_query_param_bool (return_suppressed),
- GNUNET_PQ_query_param_int64 (&limit),
- GNUNET_PQ_query_param_end
- };
+ struct GNUNET_PQ_QueryParam params[] = {
+ GNUNET_PQ_query_param_uint64 (&offset),
+ GNUNET_PQ_query_param_bool (return_suppressed),
+ GNUNET_PQ_query_param_int64 (&limit),
+ GNUNET_PQ_query_param_end
+ };
struct FeeTimeInconsistencyContext dcc = {
.cb = cb,
.cb_cls = cb_cls,
@@ -133,21 +133,24 @@ TAH_PG_get_fee_time_inconsistency (
" ORDER BY row_id DESC"
" LIMIT $3"
);
- PREPARE (pg,
- "auditor_fee_time_inconsistency_get_asc",
- "SELECT"
- " row_id"
- ",type"
- ",time"
- ",diagnostic"
- " FROM auditor_fee_time_inconsistency"
- " WHERE (row_id > $1)"
- " AND ($2 OR suppressed is false)"
- " ORDER BY row_id ASC"
- " LIMIT $3"
- );
+ PREPARE (pg,
+ "auditor_fee_time_inconsistency_get_asc",
+ "SELECT"
+ " row_id"
+ ",type"
+ ",time"
+ ",diagnostic"
+ " FROM auditor_fee_time_inconsistency"
+ " WHERE (row_id > $1)"
+ " AND ($2 OR suppressed is false)"
+ " ORDER BY row_id ASC"
+ " LIMIT $3"
+ );
qs = GNUNET_PQ_eval_prepared_multi_select (pg->conn,
- (limit > 0) ? "auditor_fee_time_inconsistency_get_asc" : "auditor_fee_time_inconsistency_get_desc",
+ (limit > 0) ?
+ "auditor_fee_time_inconsistency_get_asc"
+ :
+ "auditor_fee_time_inconsistency_get_desc",
params,
&fee_time_inconsistency_cb,
&dcc);
diff --git a/src/auditordb/pg_get_historic_denomination_revenue.c b/src/auditordb/pg_get_historic_denomination_revenue.c
index ca14e88a0..4eea62750 100644
--- a/src/auditordb/pg_get_historic_denomination_revenue.c
+++ b/src/auditordb/pg_get_historic_denomination_revenue.c
@@ -1,6 +1,3 @@
-
-
-
/*
This file is part of TALER
Copyright (C) 2024 Taler Systems SA
@@ -63,8 +60,8 @@ struct HistoricDenominationRevenueContext
*/
static void
historic_denomination_revenue_cb (void *cls,
- PGresult *result,
- unsigned int num_results)
+ PGresult *result,
+ unsigned int num_results)
{
struct HistoricDenominationRevenueContext *dcc = cls;
struct PostgresClosure *pg = dcc->pg;
@@ -79,11 +76,12 @@ historic_denomination_revenue_cb (void *cls,
GNUNET_PQ_result_spec_uint64 ("row_id", &serial_id),
- GNUNET_PQ_result_spec_auto_from_type("denom_pub_hash", &dc.denom_pub_hash),
-GNUNET_PQ_result_spec_int64("revenue_timestamp", &dc.revenue_timestamp),
-TALER_PQ_RESULT_SPEC_AMOUNT("revenue_balance", &dc.revenue_balance),
-TALER_PQ_RESULT_SPEC_AMOUNT("loss_balance", &dc.loss_balance),
-GNUNET_PQ_result_spec_bool("suppressed", &dc.suppressed),
+ GNUNET_PQ_result_spec_auto_from_type ("denom_pub_hash",
+ &dc.denom_pub_hash),
+ GNUNET_PQ_result_spec_int64 ("revenue_timestamp", &dc.revenue_timestamp),
+ TALER_PQ_RESULT_SPEC_AMOUNT ("revenue_balance", &dc.revenue_balance),
+ TALER_PQ_RESULT_SPEC_AMOUNT ("loss_balance", &dc.loss_balance),
+ GNUNET_PQ_result_spec_bool ("suppressed", &dc.suppressed),
GNUNET_PQ_result_spec_end
@@ -140,10 +138,10 @@ TAH_PG_get_historic_denomination_revenue (
"auditor_historic_denomination_revenue_get_desc",
"SELECT"
" denom_pub_hash,"
-" revenue_timestamp,"
-" revenue_balance,"
-" loss_balance,"
-" suppressed"
+ " revenue_timestamp,"
+ " revenue_balance,"
+ " loss_balance,"
+ " suppressed"
" FROM auditor_historic_denomination_revenue"
" WHERE (row_id < $1)"
" AND ($2 OR suppressed is false)"
@@ -154,10 +152,10 @@ TAH_PG_get_historic_denomination_revenue (
"auditor_historic_denomination_revenue_get_asc",
"SELECT"
" denom_pub_hash,"
-" revenue_timestamp,"
-" revenue_balance,"
-" loss_balance,"
-" suppressed"
+ " revenue_timestamp,"
+ " revenue_balance,"
+ " loss_balance,"
+ " suppressed"
" FROM auditor_historic_denomination_revenue"
" WHERE (row_id > $1)"
" AND ($2 OR suppressed is false)"
@@ -166,8 +164,10 @@ TAH_PG_get_historic_denomination_revenue (
);
qs = GNUNET_PQ_eval_prepared_multi_select (pg->conn,
(limit > 0)
- ? "auditor_historic_denomination_revenue_get_asc"
- : "auditor_historic_denomination_revenue_get_desc",
+ ?
+ "auditor_historic_denomination_revenue_get_asc"
+ :
+ "auditor_historic_denomination_revenue_get_desc",
params,
&historic_denomination_revenue_cb,
&dcc);
@@ -177,6 +177,3 @@ TAH_PG_get_historic_denomination_revenue (
GNUNET_break (GNUNET_DB_STATUS_HARD_ERROR != qs);
return qs;
}
-
-
- \ No newline at end of file
diff --git a/src/auditordb/pg_get_historic_reserve_summary.c b/src/auditordb/pg_get_historic_reserve_summary.c
index 454224533..68c0724ab 100644
--- a/src/auditordb/pg_get_historic_reserve_summary.c
+++ b/src/auditordb/pg_get_historic_reserve_summary.c
@@ -1,6 +1,3 @@
-
-
-
/*
This file is part of TALER
Copyright (C) 2024 Taler Systems SA
@@ -63,8 +60,8 @@ struct HistoricReserveSummaryContext
*/
static void
historic_reserve_summary_cb (void *cls,
- PGresult *result,
- unsigned int num_results)
+ PGresult *result,
+ unsigned int num_results)
{
struct HistoricReserveSummaryContext *dcc = cls;
struct PostgresClosure *pg = dcc->pg;
@@ -79,10 +76,10 @@ historic_reserve_summary_cb (void *cls,
GNUNET_PQ_result_spec_uint64 ("row_id", &serial_id),
- GNUNET_PQ_result_spec_int64("start_date", &dc.start_date),
-GNUNET_PQ_result_spec_int64("end_date", &dc.end_date),
-TALER_PQ_RESULT_SPEC_AMOUNT("reserve_profits", &dc.reserve_profits),
-GNUNET_PQ_result_spec_bool("suppressed", &dc.suppressed),
+ GNUNET_PQ_result_spec_int64 ("start_date", &dc.start_date),
+ GNUNET_PQ_result_spec_int64 ("end_date", &dc.end_date),
+ TALER_PQ_RESULT_SPEC_AMOUNT ("reserve_profits", &dc.reserve_profits),
+ GNUNET_PQ_result_spec_bool ("suppressed", &dc.suppressed),
GNUNET_PQ_result_spec_end
@@ -139,9 +136,9 @@ TAH_PG_get_historic_reserve_summary (
"auditor_historic_reserve_summary_get_desc",
"SELECT"
" start_date,"
-" end_date,"
-" reserve_profits,"
-" suppressed"
+ " end_date,"
+ " reserve_profits,"
+ " suppressed"
" FROM auditor_historic_reserve_summary"
" WHERE (row_id < $1)"
" AND ($2 OR suppressed is false)"
@@ -152,9 +149,9 @@ TAH_PG_get_historic_reserve_summary (
"auditor_historic_reserve_summary_get_asc",
"SELECT"
" start_date,"
-" end_date,"
-" reserve_profits,"
-" suppressed"
+ " end_date,"
+ " reserve_profits,"
+ " suppressed"
" FROM auditor_historic_reserve_summary"
" WHERE (row_id > $1)"
" AND ($2 OR suppressed is false)"
@@ -163,8 +160,10 @@ TAH_PG_get_historic_reserve_summary (
);
qs = GNUNET_PQ_eval_prepared_multi_select (pg->conn,
(limit > 0)
- ? "auditor_historic_reserve_summary_get_asc"
- : "auditor_historic_reserve_summary_get_desc",
+ ?
+ "auditor_historic_reserve_summary_get_asc"
+ :
+ "auditor_historic_reserve_summary_get_desc",
params,
&historic_reserve_summary_cb,
&dcc);
@@ -174,6 +173,3 @@ TAH_PG_get_historic_reserve_summary (
GNUNET_break (GNUNET_DB_STATUS_HARD_ERROR != qs);
return qs;
}
-
-
- \ No newline at end of file
diff --git a/src/auditordb/pg_get_misattribution_in_inconsistency.c b/src/auditordb/pg_get_misattribution_in_inconsistency.c
index a47b11306..c5e990642 100644
--- a/src/auditordb/pg_get_misattribution_in_inconsistency.c
+++ b/src/auditordb/pg_get_misattribution_in_inconsistency.c
@@ -1,6 +1,3 @@
-
-
-
/*
This file is part of TALER
Copyright (C) 2024 Taler Systems SA
@@ -63,8 +60,8 @@ struct MisattributionInInconsistencyContext
*/
static void
misattribution_in_inconsistency_cb (void *cls,
- PGresult *result,
- unsigned int num_results)
+ PGresult *result,
+ unsigned int num_results)
{
struct MisattributionInInconsistencyContext *dcc = cls;
struct PostgresClosure *pg = dcc->pg;
@@ -79,10 +76,10 @@ misattribution_in_inconsistency_cb (void *cls,
GNUNET_PQ_result_spec_uint64 ("row_id", &serial_id),
- TALER_PQ_RESULT_SPEC_AMOUNT("amount", &dc.amount),
-GNUNET_PQ_result_spec_int64("bank_row", &dc.bank_row),
-GNUNET_PQ_result_spec_auto_from_type("reserve_pub", &dc.reserve_pub),
-GNUNET_PQ_result_spec_bool("suppressed", &dc.suppressed),
+ TALER_PQ_RESULT_SPEC_AMOUNT ("amount", &dc.amount),
+ GNUNET_PQ_result_spec_int64 ("bank_row", &dc.bank_row),
+ GNUNET_PQ_result_spec_auto_from_type ("reserve_pub", &dc.reserve_pub),
+ GNUNET_PQ_result_spec_bool ("suppressed", &dc.suppressed),
GNUNET_PQ_result_spec_end
@@ -139,10 +136,10 @@ TAH_PG_get_misattribution_in_inconsistency (
"auditor_misattribution_in_inconsistency_get_desc",
"SELECT"
" row_id,"
-" amount,"
-" bank_row,"
-" reserve_pub,"
-" suppressed"
+ " amount,"
+ " bank_row,"
+ " reserve_pub,"
+ " suppressed"
" FROM auditor_misattribution_in_inconsistency"
" WHERE (row_id < $1)"
" AND ($2 OR suppressed is false)"
@@ -153,10 +150,10 @@ TAH_PG_get_misattribution_in_inconsistency (
"auditor_misattribution_in_inconsistency_get_asc",
"SELECT"
" row_id,"
-" amount,"
-" bank_row,"
-" reserve_pub,"
-" suppressed"
+ " amount,"
+ " bank_row,"
+ " reserve_pub,"
+ " suppressed"
" FROM auditor_misattribution_in_inconsistency"
" WHERE (row_id > $1)"
" AND ($2 OR suppressed is false)"
@@ -165,8 +162,10 @@ TAH_PG_get_misattribution_in_inconsistency (
);
qs = GNUNET_PQ_eval_prepared_multi_select (pg->conn,
(limit > 0)
- ? "auditor_misattribution_in_inconsistency_get_asc"
- : "auditor_misattribution_in_inconsistency_get_desc",
+ ?
+ "auditor_misattribution_in_inconsistency_get_asc"
+ :
+ "auditor_misattribution_in_inconsistency_get_desc",
params,
&misattribution_in_inconsistency_cb,
&dcc);
@@ -176,6 +175,3 @@ TAH_PG_get_misattribution_in_inconsistency (
GNUNET_break (GNUNET_DB_STATUS_HARD_ERROR != qs);
return qs;
}
-
-
- \ No newline at end of file
diff --git a/src/auditordb/pg_get_purse_not_closed_inconsistencies.c b/src/auditordb/pg_get_purse_not_closed_inconsistencies.c
index 7489f7ccb..c5e891ee0 100644
--- a/src/auditordb/pg_get_purse_not_closed_inconsistencies.c
+++ b/src/auditordb/pg_get_purse_not_closed_inconsistencies.c
@@ -108,12 +108,12 @@ TAH_PG_get_purse_not_closed_inconsistencies (
{
struct PostgresClosure *pg = cls;
- struct GNUNET_PQ_QueryParam params[] = {
- GNUNET_PQ_query_param_uint64 (&offset),
- GNUNET_PQ_query_param_bool (return_suppressed),
- GNUNET_PQ_query_param_int64 (&limit),
- GNUNET_PQ_query_param_end
- };
+ struct GNUNET_PQ_QueryParam params[] = {
+ GNUNET_PQ_query_param_uint64 (&offset),
+ GNUNET_PQ_query_param_bool (return_suppressed),
+ GNUNET_PQ_query_param_int64 (&limit),
+ GNUNET_PQ_query_param_end
+ };
struct PurseNotClosedInconsistenciesContext dcc = {
.cb = cb,
.cb_cls = cb_cls,
@@ -134,21 +134,24 @@ TAH_PG_get_purse_not_closed_inconsistencies (
" ORDER BY row_id DESC"
" LIMIT $3"
);
- PREPARE (pg,
- "auditor_purse_not_closed_inconsistencies_get_asc",
- "SELECT"
- " row_id"
- ",purse_pub"
- ",amount"
- ",expiration_date"
- " FROM auditor_purse_not_closed_inconsistencies"
- " WHERE (row_id > $1)"
- " AND ($2 OR suppressed is false)"
- " ORDER BY row_id ASC"
- " LIMIT $3"
- );
+ PREPARE (pg,
+ "auditor_purse_not_closed_inconsistencies_get_asc",
+ "SELECT"
+ " row_id"
+ ",purse_pub"
+ ",amount"
+ ",expiration_date"
+ " FROM auditor_purse_not_closed_inconsistencies"
+ " WHERE (row_id > $1)"
+ " AND ($2 OR suppressed is false)"
+ " ORDER BY row_id ASC"
+ " LIMIT $3"
+ );
qs = GNUNET_PQ_eval_prepared_multi_select (pg->conn,
- (limit > 0) ? "auditor_purse_not_closed_inconsistencies_get_asc" : "auditor_purse_not_closed_inconsistencies_get_desc",
+ (limit > 0) ?
+ "auditor_purse_not_closed_inconsistencies_get_asc"
+ :
+ "auditor_purse_not_closed_inconsistencies_get_desc",
params,
&
purse_not_closed_inconsistencies_cb,
diff --git a/src/auditordb/pg_get_purses.c b/src/auditordb/pg_get_purses.c
index a977a1a94..ce4ae6001 100644
--- a/src/auditordb/pg_get_purses.c
+++ b/src/auditordb/pg_get_purses.c
@@ -1,6 +1,3 @@
-
-
-
/*
This file is part of TALER
Copyright (C) 2024 Taler Systems SA
@@ -63,8 +60,8 @@ struct PursesContext
*/
static void
purses_cb (void *cls,
- PGresult *result,
- unsigned int num_results)
+ PGresult *result,
+ unsigned int num_results)
{
struct PursesContext *dcc = cls;
struct PostgresClosure *pg = dcc->pg;
@@ -79,12 +76,13 @@ purses_cb (void *cls,
GNUNET_PQ_result_spec_uint64 ("row_id", &serial_id),
- GNUNET_PQ_result_spec_int64("auditor_purses_rowid", &dc.auditor_purses_rowid),
-GNUNET_PQ_result_spec_auto_from_type("purse_pub", &dc.purse_pub),
-TALER_PQ_RESULT_SPEC_AMOUNT("balance", &dc.balance),
-TALER_PQ_RESULT_SPEC_AMOUNT("target", &dc.target),
-GNUNET_PQ_result_spec_int64("expiration_date", &dc.expiration_date),
-GNUNET_PQ_result_spec_bool("suppressed", &dc.suppressed),
+ GNUNET_PQ_result_spec_int64 ("auditor_purses_rowid",
+ &dc.auditor_purses_rowid),
+ GNUNET_PQ_result_spec_auto_from_type ("purse_pub", &dc.purse_pub),
+ TALER_PQ_RESULT_SPEC_AMOUNT ("balance", &dc.balance),
+ TALER_PQ_RESULT_SPEC_AMOUNT ("target", &dc.target),
+ GNUNET_PQ_result_spec_int64 ("expiration_date", &dc.expiration_date),
+ GNUNET_PQ_result_spec_bool ("suppressed", &dc.suppressed),
GNUNET_PQ_result_spec_end
@@ -141,11 +139,11 @@ TAH_PG_get_purses (
"auditor_purses_get_desc",
"SELECT"
" auditor_purses_rowid,"
-" purse_pub,"
-" balance,"
-" target,"
-" expiration_date,"
-" suppressed"
+ " purse_pub,"
+ " balance,"
+ " target,"
+ " expiration_date,"
+ " suppressed"
" FROM auditor_purses"
" WHERE (row_id < $1)"
" AND ($2 OR suppressed is false)"
@@ -156,11 +154,11 @@ TAH_PG_get_purses (
"auditor_purses_get_asc",
"SELECT"
" auditor_purses_rowid,"
-" purse_pub,"
-" balance,"
-" target,"
-" expiration_date,"
-" suppressed"
+ " purse_pub,"
+ " balance,"
+ " target,"
+ " expiration_date,"
+ " suppressed"
" FROM auditor_purses"
" WHERE (row_id > $1)"
" AND ($2 OR suppressed is false)"
@@ -180,6 +178,3 @@ TAH_PG_get_purses (
GNUNET_break (GNUNET_DB_STATUS_HARD_ERROR != qs);
return qs;
}
-
-
- \ No newline at end of file
diff --git a/src/auditordb/pg_get_refreshes_hanging.c b/src/auditordb/pg_get_refreshes_hanging.c
index d4dd83b67..6d86ae7a6 100644
--- a/src/auditordb/pg_get_refreshes_hanging.c
+++ b/src/auditordb/pg_get_refreshes_hanging.c
@@ -106,12 +106,12 @@ TAH_PG_get_refreshes_hanging (
{
struct PostgresClosure *pg = cls;
- struct GNUNET_PQ_QueryParam params[] = {
- GNUNET_PQ_query_param_uint64 (&offset),
- GNUNET_PQ_query_param_bool (return_suppressed),
- GNUNET_PQ_query_param_int64 (&limit),
- GNUNET_PQ_query_param_end
- };
+ struct GNUNET_PQ_QueryParam params[] = {
+ GNUNET_PQ_query_param_uint64 (&offset),
+ GNUNET_PQ_query_param_bool (return_suppressed),
+ GNUNET_PQ_query_param_int64 (&limit),
+ GNUNET_PQ_query_param_end
+ };
struct RefreshesHangingContext dcc = {
.cb = cb,
.cb_cls = cb_cls,
@@ -131,20 +131,22 @@ TAH_PG_get_refreshes_hanging (
" ORDER BY row_id DESC"
" LIMIT $3"
);
- PREPARE (pg,
- "auditor_refreshes_hanging_get_asc",
- "SELECT"
- " row_id"
- ",amount"
- ",coin_pub"
- " FROM auditor_refreshes_hanging"
- " WHERE (row_id > $1)"
- " AND ($2 OR suppressed is false)"
- " ORDER BY row_id ASC"
- " LIMIT $3"
- );
+ PREPARE (pg,
+ "auditor_refreshes_hanging_get_asc",
+ "SELECT"
+ " row_id"
+ ",amount"
+ ",coin_pub"
+ " FROM auditor_refreshes_hanging"
+ " WHERE (row_id > $1)"
+ " AND ($2 OR suppressed is false)"
+ " ORDER BY row_id ASC"
+ " LIMIT $3"
+ );
qs = GNUNET_PQ_eval_prepared_multi_select (pg->conn,
- (limit > 0) ? "auditor_refreshes_hanging_get_asc" : "auditor_refreshes_hanging_get_desc",
+ (limit > 0) ?
+ "auditor_refreshes_hanging_get_asc"
+ : "auditor_refreshes_hanging_get_desc",
params,
&refreshes_hanging_cb,
&dcc);
diff --git a/src/auditordb/pg_get_reserve_balance_insufficient_inconsistency.c b/src/auditordb/pg_get_reserve_balance_insufficient_inconsistency.c
index 4182e5dc9..ed482937b 100644
--- a/src/auditordb/pg_get_reserve_balance_insufficient_inconsistency.c
+++ b/src/auditordb/pg_get_reserve_balance_insufficient_inconsistency.c
@@ -108,12 +108,12 @@ TAH_PG_get_reserve_balance_insufficient_inconsistency (
{
struct PostgresClosure *pg = cls;
- struct GNUNET_PQ_QueryParam params[] = {
- GNUNET_PQ_query_param_uint64 (&offset),
- GNUNET_PQ_query_param_bool (return_suppressed),
- GNUNET_PQ_query_param_int64 (&limit),
- GNUNET_PQ_query_param_end
- };
+ struct GNUNET_PQ_QueryParam params[] = {
+ GNUNET_PQ_query_param_uint64 (&offset),
+ GNUNET_PQ_query_param_bool (return_suppressed),
+ GNUNET_PQ_query_param_int64 (&limit),
+ GNUNET_PQ_query_param_end
+ };
struct ReserveBalanceInsufficientInconsistencyContext dcc = {
.cb = cb,
.cb_cls = cb_cls,
@@ -134,21 +134,24 @@ TAH_PG_get_reserve_balance_insufficient_inconsistency (
" ORDER BY row_id DESC"
" LIMIT $3"
);
- PREPARE (pg,
- "auditor_reserve_balance_insufficient_inconsistency_get_asc",
- "SELECT"
- " row_id"
- ",reserve_pub"
- ",inconsistency_gain"
- ",inconsistency_amount"
- " FROM auditor_reserve_balance_insufficient_inconsistency"
- " WHERE (row_id > $1)"
- " AND ($2 OR suppressed is false)"
- " ORDER BY row_id ASC"
- " LIMIT $3"
- );
+ PREPARE (pg,
+ "auditor_reserve_balance_insufficient_inconsistency_get_asc",
+ "SELECT"
+ " row_id"
+ ",reserve_pub"
+ ",inconsistency_gain"
+ ",inconsistency_amount"
+ " FROM auditor_reserve_balance_insufficient_inconsistency"
+ " WHERE (row_id > $1)"
+ " AND ($2 OR suppressed is false)"
+ " ORDER BY row_id ASC"
+ " LIMIT $3"
+ );
qs = GNUNET_PQ_eval_prepared_multi_select (pg->conn,
- (limit > 0) ? "auditor_reserve_balance_insufficient_inconsistency_get_asc" : "auditor_reserve_balance_insufficient_inconsistency_get_desc",
+ (limit > 0) ?
+ "auditor_reserve_balance_insufficient_inconsistency_get_asc"
+ :
+ "auditor_reserve_balance_insufficient_inconsistency_get_desc",
params,
&
reserve_balance_insufficient_inconsistency_cb,
diff --git a/src/auditordb/pg_get_reserve_balance_summary_wrong_inconsistency.c b/src/auditordb/pg_get_reserve_balance_summary_wrong_inconsistency.c
index 5e7ac3533..a2ae412f0 100644
--- a/src/auditordb/pg_get_reserve_balance_summary_wrong_inconsistency.c
+++ b/src/auditordb/pg_get_reserve_balance_summary_wrong_inconsistency.c
@@ -1,6 +1,3 @@
-
-
-
/*
This file is part of TALER
Copyright (C) 2024 Taler Systems SA
@@ -63,8 +60,8 @@ struct ReserveBalanceSummaryWrongInconsistencyContext
*/
static void
reserve_balance_summary_wrong_inconsistency_cb (void *cls,
- PGresult *result,
- unsigned int num_results)
+ PGresult *result,
+ unsigned int num_results)
{
struct ReserveBalanceSummaryWrongInconsistencyContext *dcc = cls;
struct PostgresClosure *pg = dcc->pg;
@@ -79,10 +76,10 @@ reserve_balance_summary_wrong_inconsistency_cb (void *cls,
GNUNET_PQ_result_spec_uint64 ("row_id", &serial_id),
- GNUNET_PQ_result_spec_auto_from_type("reserve_pub", &dc.reserve_pub),
-TALER_PQ_RESULT_SPEC_AMOUNT("exchange_amount", &dc.exchange_amount),
-TALER_PQ_RESULT_SPEC_AMOUNT("auditor_amount", &dc.auditor_amount),
-GNUNET_PQ_result_spec_bool("suppressed", &dc.suppressed),
+ GNUNET_PQ_result_spec_auto_from_type ("reserve_pub", &dc.reserve_pub),
+ TALER_PQ_RESULT_SPEC_AMOUNT ("exchange_amount", &dc.exchange_amount),
+ TALER_PQ_RESULT_SPEC_AMOUNT ("auditor_amount", &dc.auditor_amount),
+ GNUNET_PQ_result_spec_bool ("suppressed", &dc.suppressed),
GNUNET_PQ_result_spec_end
@@ -139,10 +136,10 @@ TAH_PG_get_reserve_balance_summary_wrong_inconsistency (
"auditor_reserve_balance_summary_wrong_inconsistency_get_desc",
"SELECT"
" row_id,"
-" reserve_pub,"
-" exchange_amount,"
-" auditor_amount,"
-" suppressed"
+ " reserve_pub,"
+ " exchange_amount,"
+ " auditor_amount,"
+ " suppressed"
" FROM auditor_reserve_balance_summary_wrong_inconsistency"
" WHERE (row_id < $1)"
" AND ($2 OR suppressed is false)"
@@ -153,10 +150,10 @@ TAH_PG_get_reserve_balance_summary_wrong_inconsistency (
"auditor_reserve_balance_summary_wrong_inconsistency_get_asc",
"SELECT"
" row_id,"
-" reserve_pub,"
-" exchange_amount,"
-" auditor_amount,"
-" suppressed"
+ " reserve_pub,"
+ " exchange_amount,"
+ " auditor_amount,"
+ " suppressed"
" FROM auditor_reserve_balance_summary_wrong_inconsistency"
" WHERE (row_id > $1)"
" AND ($2 OR suppressed is false)"
@@ -165,10 +162,13 @@ TAH_PG_get_reserve_balance_summary_wrong_inconsistency (
);
qs = GNUNET_PQ_eval_prepared_multi_select (pg->conn,
(limit > 0)
- ? "auditor_reserve_balance_summary_wrong_inconsistency_get_asc"
- : "auditor_reserve_balance_summary_wrong_inconsistency_get_desc",
+ ?
+ "auditor_reserve_balance_summary_wrong_inconsistency_get_asc"
+ :
+ "auditor_reserve_balance_summary_wrong_inconsistency_get_desc",
params,
- &reserve_balance_summary_wrong_inconsistency_cb,
+ &
+ reserve_balance_summary_wrong_inconsistency_cb,
&dcc);
if (qs > 0)
@@ -176,6 +176,3 @@ TAH_PG_get_reserve_balance_summary_wrong_inconsistency (
GNUNET_break (GNUNET_DB_STATUS_HARD_ERROR != qs);
return qs;
}
-
-
- \ No newline at end of file
diff --git a/src/auditordb/pg_get_reserve_in_inconsistency.c b/src/auditordb/pg_get_reserve_in_inconsistency.c
index 22950f537..1ad3559ac 100644
--- a/src/auditordb/pg_get_reserve_in_inconsistency.c
+++ b/src/auditordb/pg_get_reserve_in_inconsistency.c
@@ -1,6 +1,3 @@
-
-
-
/*
This file is part of TALER
Copyright (C) 2024 Taler Systems SA
@@ -63,8 +60,8 @@ struct ReserveInInconsistencyContext
*/
static void
reserve_in_inconsistency_cb (void *cls,
- PGresult *result,
- unsigned int num_results)
+ PGresult *result,
+ unsigned int num_results)
{
struct ReserveInInconsistencyContext *dcc = cls;
struct PostgresClosure *pg = dcc->pg;
@@ -79,13 +76,14 @@ reserve_in_inconsistency_cb (void *cls,
GNUNET_PQ_result_spec_uint64 ("row_id", &serial_id),
- TALER_PQ_RESULT_SPEC_AMOUNT("amount_exchange_expected", &dc.amount_exchange_expected),
-TALER_PQ_RESULT_SPEC_AMOUNT("amount_wired", &dc.amount_wired),
-GNUNET_PQ_result_spec_auto_from_type("reserve_pub", &dc.reserve_pub),
-GNUNET_PQ_result_spec_int64("timestamp", &dc.timestamp),
-GNUNET_PQ_result_spec_auto_from_type("account", &dc.account),
-GNUNET_PQ_result_spec_auto_from_type("diagnostic", &dc.diagnostic),
-GNUNET_PQ_result_spec_bool("suppressed", &dc.suppressed),
+ TALER_PQ_RESULT_SPEC_AMOUNT ("amount_exchange_expected",
+ &dc.amount_exchange_expected),
+ TALER_PQ_RESULT_SPEC_AMOUNT ("amount_wired", &dc.amount_wired),
+ GNUNET_PQ_result_spec_auto_from_type ("reserve_pub", &dc.reserve_pub),
+ GNUNET_PQ_result_spec_int64 ("timestamp", &dc.timestamp),
+ GNUNET_PQ_result_spec_auto_from_type ("account", &dc.account),
+ GNUNET_PQ_result_spec_auto_from_type ("diagnostic", &dc.diagnostic),
+ GNUNET_PQ_result_spec_bool ("suppressed", &dc.suppressed),
GNUNET_PQ_result_spec_end
@@ -142,13 +140,13 @@ TAH_PG_get_reserve_in_inconsistency (
"auditor_reserve_in_inconsistency_get_desc",
"SELECT"
" row_id,"
-" amount_exchange_expected,"
-" amount_wired,"
-" reserve_pub,"
-" timestamp,"
-" account,"
-" diagnostic,"
-" suppressed"
+ " amount_exchange_expected,"
+ " amount_wired,"
+ " reserve_pub,"
+ " timestamp,"
+ " account,"
+ " diagnostic,"
+ " suppressed"
" FROM auditor_reserve_in_inconsistency"
" WHERE (row_id < $1)"
" AND ($2 OR suppressed is false)"
@@ -159,13 +157,13 @@ TAH_PG_get_reserve_in_inconsistency (
"auditor_reserve_in_inconsistency_get_asc",
"SELECT"
" row_id,"
-" amount_exchange_expected,"
-" amount_wired,"
-" reserve_pub,"
-" timestamp,"
-" account,"
-" diagnostic,"
-" suppressed"
+ " amount_exchange_expected,"
+ " amount_wired,"
+ " reserve_pub,"
+ " timestamp,"
+ " account,"
+ " diagnostic,"
+ " suppressed"
" FROM auditor_reserve_in_inconsistency"
" WHERE (row_id > $1)"
" AND ($2 OR suppressed is false)"
@@ -174,8 +172,10 @@ TAH_PG_get_reserve_in_inconsistency (
);
qs = GNUNET_PQ_eval_prepared_multi_select (pg->conn,
(limit > 0)
- ? "auditor_reserve_in_inconsistency_get_asc"
- : "auditor_reserve_in_inconsistency_get_desc",
+ ?
+ "auditor_reserve_in_inconsistency_get_asc"
+ :
+ "auditor_reserve_in_inconsistency_get_desc",
params,
&reserve_in_inconsistency_cb,
&dcc);
@@ -185,6 +185,3 @@ TAH_PG_get_reserve_in_inconsistency (
GNUNET_break (GNUNET_DB_STATUS_HARD_ERROR != qs);
return qs;
}
-
-
- \ No newline at end of file
diff --git a/src/auditordb/pg_get_reserve_not_closed_inconsistency.c b/src/auditordb/pg_get_reserve_not_closed_inconsistency.c
index ebef6697f..3a47f759a 100644
--- a/src/auditordb/pg_get_reserve_not_closed_inconsistency.c
+++ b/src/auditordb/pg_get_reserve_not_closed_inconsistency.c
@@ -1,6 +1,3 @@
-
-
-
/*
This file is part of TALER
Copyright (C) 2024 Taler Systems SA
@@ -63,8 +60,8 @@ struct ReserveNotClosedInconsistencyContext
*/
static void
reserve_not_closed_inconsistency_cb (void *cls,
- PGresult *result,
- unsigned int num_results)
+ PGresult *result,
+ unsigned int num_results)
{
struct ReserveNotClosedInconsistencyContext *dcc = cls;
struct PostgresClosure *pg = dcc->pg;
@@ -79,11 +76,11 @@ reserve_not_closed_inconsistency_cb (void *cls,
GNUNET_PQ_result_spec_uint64 ("row_id", &serial_id),
- GNUNET_PQ_result_spec_auto_from_type("reserve_pub", &dc.reserve_pub),
-TALER_PQ_RESULT_SPEC_AMOUNT("balance", &dc.balance),
-GNUNET_PQ_result_spec_int64("expiration_time", &dc.expiration_time),
-GNUNET_PQ_result_spec_auto_from_type("diagnostic", &dc.diagnostic),
-GNUNET_PQ_result_spec_bool("suppressed", &dc.suppressed),
+ GNUNET_PQ_result_spec_auto_from_type ("reserve_pub", &dc.reserve_pub),
+ TALER_PQ_RESULT_SPEC_AMOUNT ("balance", &dc.balance),
+ GNUNET_PQ_result_spec_int64 ("expiration_time", &dc.expiration_time),
+ GNUNET_PQ_result_spec_auto_from_type ("diagnostic", &dc.diagnostic),
+ GNUNET_PQ_result_spec_bool ("suppressed", &dc.suppressed),
GNUNET_PQ_result_spec_end
@@ -140,11 +137,11 @@ TAH_PG_get_reserve_not_closed_inconsistency (
"auditor_reserve_not_closed_inconsistency_get_desc",
"SELECT"
" row_id,"
-" reserve_pub,"
-" balance,"
-" expiration_time,"
-" diagnostic,"
-" suppressed"
+ " reserve_pub,"
+ " balance,"
+ " expiration_time,"
+ " diagnostic,"
+ " suppressed"
" FROM auditor_reserve_not_closed_inconsistency"
" WHERE (row_id < $1)"
" AND ($2 OR suppressed is false)"
@@ -155,11 +152,11 @@ TAH_PG_get_reserve_not_closed_inconsistency (
"auditor_reserve_not_closed_inconsistency_get_asc",
"SELECT"
" row_id,"
-" reserve_pub,"
-" balance,"
-" expiration_time,"
-" diagnostic,"
-" suppressed"
+ " reserve_pub,"
+ " balance,"
+ " expiration_time,"
+ " diagnostic,"
+ " suppressed"
" FROM auditor_reserve_not_closed_inconsistency"
" WHERE (row_id > $1)"
" AND ($2 OR suppressed is false)"
@@ -168,10 +165,13 @@ TAH_PG_get_reserve_not_closed_inconsistency (
);
qs = GNUNET_PQ_eval_prepared_multi_select (pg->conn,
(limit > 0)
- ? "auditor_reserve_not_closed_inconsistency_get_asc"
- : "auditor_reserve_not_closed_inconsistency_get_desc",
+ ?
+ "auditor_reserve_not_closed_inconsistency_get_asc"
+ :
+ "auditor_reserve_not_closed_inconsistency_get_desc",
params,
- &reserve_not_closed_inconsistency_cb,
+ &
+ reserve_not_closed_inconsistency_cb,
&dcc);
if (qs > 0)
@@ -179,6 +179,3 @@ TAH_PG_get_reserve_not_closed_inconsistency (
GNUNET_break (GNUNET_DB_STATUS_HARD_ERROR != qs);
return qs;
}
-
-
- \ No newline at end of file
diff --git a/src/auditordb/pg_get_reserves.c b/src/auditordb/pg_get_reserves.c
index 8eefba898..9bb817d5f 100644
--- a/src/auditordb/pg_get_reserves.c
+++ b/src/auditordb/pg_get_reserves.c
@@ -1,6 +1,3 @@
-
-
-
/*
This file is part of TALER
Copyright (C) 2024 Taler Systems SA
@@ -63,8 +60,8 @@ struct ReservesContext
*/
static void
reserves_cb (void *cls,
- PGresult *result,
- unsigned int num_results)
+ PGresult *result,
+ unsigned int num_results)
{
struct ReservesContext *dcc = cls;
struct PostgresClosure *pg = dcc->pg;
@@ -79,18 +76,21 @@ reserves_cb (void *cls,
GNUNET_PQ_result_spec_uint64 ("row_id", &serial_id),
- GNUNET_PQ_result_spec_int64("auditor_reserves_rowid", &dc.auditor_reserves_rowid),
-GNUNET_PQ_result_spec_auto_from_type("reserve_pub", &dc.reserve_pub),
-TALER_PQ_RESULT_SPEC_AMOUNT("reserve_balance", &dc.reserve_balance),
-TALER_PQ_RESULT_SPEC_AMOUNT("reserve_loss", &dc.reserve_loss),
-TALER_PQ_RESULT_SPEC_AMOUNT("withdraw_fee_balance", &dc.withdraw_fee_balance),
-TALER_PQ_RESULT_SPEC_AMOUNT("close_fee_balance", &dc.close_fee_balance),
-TALER_PQ_RESULT_SPEC_AMOUNT("purse_fee_balance", &dc.purse_fee_balance),
-TALER_PQ_RESULT_SPEC_AMOUNT("open_fee_balance", &dc.open_fee_balance),
-TALER_PQ_RESULT_SPEC_AMOUNT("history_fee_balance", &dc.history_fee_balance),
-GNUNET_PQ_result_spec_int64("expiration_date", &dc.expiration_date),
-GNUNET_PQ_result_spec_string("origin_account", &dc.origin_account),
-GNUNET_PQ_result_spec_bool("suppressed", &dc.suppressed),
+ GNUNET_PQ_result_spec_int64 ("auditor_reserves_rowid",
+ &dc.auditor_reserves_rowid),
+ GNUNET_PQ_result_spec_auto_from_type ("reserve_pub", &dc.reserve_pub),
+ TALER_PQ_RESULT_SPEC_AMOUNT ("reserve_balance", &dc.reserve_balance),
+ TALER_PQ_RESULT_SPEC_AMOUNT ("reserve_loss", &dc.reserve_loss),
+ TALER_PQ_RESULT_SPEC_AMOUNT ("withdraw_fee_balance",
+ &dc.withdraw_fee_balance),
+ TALER_PQ_RESULT_SPEC_AMOUNT ("close_fee_balance", &dc.close_fee_balance),
+ TALER_PQ_RESULT_SPEC_AMOUNT ("purse_fee_balance", &dc.purse_fee_balance),
+ TALER_PQ_RESULT_SPEC_AMOUNT ("open_fee_balance", &dc.open_fee_balance),
+ TALER_PQ_RESULT_SPEC_AMOUNT ("history_fee_balance",
+ &dc.history_fee_balance),
+ GNUNET_PQ_result_spec_int64 ("expiration_date", &dc.expiration_date),
+ GNUNET_PQ_result_spec_string ("origin_account", &dc.origin_account),
+ GNUNET_PQ_result_spec_bool ("suppressed", &dc.suppressed),
GNUNET_PQ_result_spec_end
@@ -147,17 +147,17 @@ TAH_PG_get_reserves (
"auditor_reserves_get_desc",
"SELECT"
" auditor_reserves_rowid,"
-" reserve_pub,"
-" reserve_balance,"
-" reserve_loss,"
-" withdraw_fee_balance,"
-" close_fee_balance,"
-" purse_fee_balance,"
-" open_fee_balance,"
-" history_fee_balance,"
-" expiration_date,"
-" origin_account,"
-" suppressed"
+ " reserve_pub,"
+ " reserve_balance,"
+ " reserve_loss,"
+ " withdraw_fee_balance,"
+ " close_fee_balance,"
+ " purse_fee_balance,"
+ " open_fee_balance,"
+ " history_fee_balance,"
+ " expiration_date,"
+ " origin_account,"
+ " suppressed"
" FROM auditor_reserves"
" WHERE (row_id < $1)"
" AND ($2 OR suppressed is false)"
@@ -168,17 +168,17 @@ TAH_PG_get_reserves (
"auditor_reserves_get_asc",
"SELECT"
" auditor_reserves_rowid,"
-" reserve_pub,"
-" reserve_balance,"
-" reserve_loss,"
-" withdraw_fee_balance,"
-" close_fee_balance,"
-" purse_fee_balance,"
-" open_fee_balance,"
-" history_fee_balance,"
-" expiration_date,"
-" origin_account,"
-" suppressed"
+ " reserve_pub,"
+ " reserve_balance,"
+ " reserve_loss,"
+ " withdraw_fee_balance,"
+ " close_fee_balance,"
+ " purse_fee_balance,"
+ " open_fee_balance,"
+ " history_fee_balance,"
+ " expiration_date,"
+ " origin_account,"
+ " suppressed"
" FROM auditor_reserves"
" WHERE (row_id > $1)"
" AND ($2 OR suppressed is false)"
@@ -198,6 +198,3 @@ TAH_PG_get_reserves (
GNUNET_break (GNUNET_DB_STATUS_HARD_ERROR != qs);
return qs;
}
-
-
- \ No newline at end of file
diff --git a/src/auditordb/pg_get_row_inconsistency.c b/src/auditordb/pg_get_row_inconsistency.c
index 67f83f6ed..f90d1cf0e 100644
--- a/src/auditordb/pg_get_row_inconsistency.c
+++ b/src/auditordb/pg_get_row_inconsistency.c
@@ -107,12 +107,12 @@ TAH_PG_get_row_inconsistency (
{
struct PostgresClosure *pg = cls;
- struct GNUNET_PQ_QueryParam params[] = {
- GNUNET_PQ_query_param_uint64 (&offset),
- GNUNET_PQ_query_param_bool (return_suppressed),
- GNUNET_PQ_query_param_int64 (&limit),
- GNUNET_PQ_query_param_end
- };
+ struct GNUNET_PQ_QueryParam params[] = {
+ GNUNET_PQ_query_param_uint64 (&offset),
+ GNUNET_PQ_query_param_bool (return_suppressed),
+ GNUNET_PQ_query_param_int64 (&limit),
+ GNUNET_PQ_query_param_end
+ };
struct RowInconsistencyContext dcc = {
.cb = cb,
.cb_cls = cb_cls,
@@ -133,20 +133,23 @@ TAH_PG_get_row_inconsistency (
" ORDER BY row_id DESC"
" LIMIT $3"
);
- PREPARE (pg,
- "auditor_row_inconsistency_select_asc",
- "SELECT"
- " row_id"
- ",row_table"
- ",diagnostic"
- " FROM auditor_row_inconsistency"
- " WHERE (row_id > $1)"
- " AND ($2 OR suppressed is false)"
- " ORDER BY row_id DESC"
- " LIMIT $3"
- );
+ PREPARE (pg,
+ "auditor_row_inconsistency_select_asc",
+ "SELECT"
+ " row_id"
+ ",row_table"
+ ",diagnostic"
+ " FROM auditor_row_inconsistency"
+ " WHERE (row_id > $1)"
+ " AND ($2 OR suppressed is false)"
+ " ORDER BY row_id DESC"
+ " LIMIT $3"
+ );
qs = GNUNET_PQ_eval_prepared_multi_select (pg->conn,
- (limit > 0) ? "auditor_row_inconsistency_select_asc" : "auditor_row_inconsistency_select_desc",
+ (limit > 0) ?
+ "auditor_row_inconsistency_select_asc"
+ :
+ "auditor_row_inconsistency_select_desc",
params,
&row_inconsistency_cb,
&dcc);
diff --git a/src/auditordb/pg_get_row_minor_inconsistencies.c b/src/auditordb/pg_get_row_minor_inconsistencies.c
index 002abbda3..8308d5dbb 100644
--- a/src/auditordb/pg_get_row_minor_inconsistencies.c
+++ b/src/auditordb/pg_get_row_minor_inconsistencies.c
@@ -1,6 +1,3 @@
-
-
-
/*
This file is part of TALER
Copyright (C) 2024 Taler Systems SA
@@ -63,8 +60,8 @@ struct RowMinorInconsistenciesContext
*/
static void
row_minor_inconsistencies_cb (void *cls,
- PGresult *result,
- unsigned int num_results)
+ PGresult *result,
+ unsigned int num_results)
{
struct RowMinorInconsistenciesContext *dcc = cls;
struct PostgresClosure *pg = dcc->pg;
@@ -79,9 +76,9 @@ row_minor_inconsistencies_cb (void *cls,
GNUNET_PQ_result_spec_uint64 ("row_id", &serial_id),
- GNUNET_PQ_result_spec_auto_from_type("row_table", &dc.row_table),
-GNUNET_PQ_result_spec_auto_from_type("diagnostic", &dc.diagnostic),
-GNUNET_PQ_result_spec_bool("suppressed", &dc.suppressed),
+ GNUNET_PQ_result_spec_auto_from_type ("row_table", &dc.row_table),
+ GNUNET_PQ_result_spec_auto_from_type ("diagnostic", &dc.diagnostic),
+ GNUNET_PQ_result_spec_bool ("suppressed", &dc.suppressed),
GNUNET_PQ_result_spec_end
@@ -138,9 +135,9 @@ TAH_PG_get_row_minor_inconsistencies (
"auditor_row_minor_inconsistencies_get_desc",
"SELECT"
" row_id,"
-" row_table,"
-" diagnostic,"
-" suppressed"
+ " row_table,"
+ " diagnostic,"
+ " suppressed"
" FROM auditor_row_minor_inconsistencies"
" WHERE (row_id < $1)"
" AND ($2 OR suppressed is false)"
@@ -151,9 +148,9 @@ TAH_PG_get_row_minor_inconsistencies (
"auditor_row_minor_inconsistencies_get_asc",
"SELECT"
" row_id,"
-" row_table,"
-" diagnostic,"
-" suppressed"
+ " row_table,"
+ " diagnostic,"
+ " suppressed"
" FROM auditor_row_minor_inconsistencies"
" WHERE (row_id > $1)"
" AND ($2 OR suppressed is false)"
@@ -162,8 +159,10 @@ TAH_PG_get_row_minor_inconsistencies (
);
qs = GNUNET_PQ_eval_prepared_multi_select (pg->conn,
(limit > 0)
- ? "auditor_row_minor_inconsistencies_get_asc"
- : "auditor_row_minor_inconsistencies_get_desc",
+ ?
+ "auditor_row_minor_inconsistencies_get_asc"
+ :
+ "auditor_row_minor_inconsistencies_get_desc",
params,
&row_minor_inconsistencies_cb,
&dcc);
@@ -173,6 +172,3 @@ TAH_PG_get_row_minor_inconsistencies (
GNUNET_break (GNUNET_DB_STATUS_HARD_ERROR != qs);
return qs;
}
-
-
- \ No newline at end of file
diff --git a/src/auditordb/pg_get_wire_format_inconsistency.c b/src/auditordb/pg_get_wire_format_inconsistency.c
index ec443616e..b3ab1b60d 100644
--- a/src/auditordb/pg_get_wire_format_inconsistency.c
+++ b/src/auditordb/pg_get_wire_format_inconsistency.c
@@ -1,6 +1,3 @@
-
-
-
/*
This file is part of TALER
Copyright (C) 2024 Taler Systems SA
@@ -63,8 +60,8 @@ struct WireFormatInconsistencyContext
*/
static void
wire_format_inconsistency_cb (void *cls,
- PGresult *result,
- unsigned int num_results)
+ PGresult *result,
+ unsigned int num_results)
{
struct WireFormatInconsistencyContext *dcc = cls;
struct PostgresClosure *pg = dcc->pg;
@@ -79,10 +76,10 @@ wire_format_inconsistency_cb (void *cls,
GNUNET_PQ_result_spec_uint64 ("row_id", &serial_id),
- TALER_PQ_RESULT_SPEC_AMOUNT("amount", &dc.amount),
-GNUNET_PQ_result_spec_int64("wire_offset", &dc.wire_offset),
-GNUNET_PQ_result_spec_auto_from_type("diagnostic", &dc.diagnostic),
-GNUNET_PQ_result_spec_bool("suppressed", &dc.suppressed),
+ TALER_PQ_RESULT_SPEC_AMOUNT ("amount", &dc.amount),
+ GNUNET_PQ_result_spec_int64 ("wire_offset", &dc.wire_offset),
+ GNUNET_PQ_result_spec_auto_from_type ("diagnostic", &dc.diagnostic),
+ GNUNET_PQ_result_spec_bool ("suppressed", &dc.suppressed),
GNUNET_PQ_result_spec_end
@@ -139,10 +136,10 @@ TAH_PG_get_wire_format_inconsistency (
"auditor_wire_format_inconsistency_get_desc",
"SELECT"
" row_id,"
-" amount,"
-" wire_offset,"
-" diagnostic,"
-" suppressed"
+ " amount,"
+ " wire_offset,"
+ " diagnostic,"
+ " suppressed"
" FROM auditor_wire_format_inconsistency"
" WHERE (row_id < $1)"
" AND ($2 OR suppressed is false)"
@@ -153,10 +150,10 @@ TAH_PG_get_wire_format_inconsistency (
"auditor_wire_format_inconsistency_get_asc",
"SELECT"
" row_id,"
-" amount,"
-" wire_offset,"
-" diagnostic,"
-" suppressed"
+ " amount,"
+ " wire_offset,"
+ " diagnostic,"
+ " suppressed"
" FROM auditor_wire_format_inconsistency"
" WHERE (row_id > $1)"
" AND ($2 OR suppressed is false)"
@@ -165,8 +162,10 @@ TAH_PG_get_wire_format_inconsistency (
);
qs = GNUNET_PQ_eval_prepared_multi_select (pg->conn,
(limit > 0)
- ? "auditor_wire_format_inconsistency_get_asc"
- : "auditor_wire_format_inconsistency_get_desc",
+ ?
+ "auditor_wire_format_inconsistency_get_asc"
+ :
+ "auditor_wire_format_inconsistency_get_desc",
params,
&wire_format_inconsistency_cb,
&dcc);
@@ -176,6 +175,3 @@ TAH_PG_get_wire_format_inconsistency (
GNUNET_break (GNUNET_DB_STATUS_HARD_ERROR != qs);
return qs;
}
-
-
- \ No newline at end of file
diff --git a/src/auditordb/pg_get_wire_out_inconsistency.c b/src/auditordb/pg_get_wire_out_inconsistency.c
index f9394375d..3a7051ad3 100644
--- a/src/auditordb/pg_get_wire_out_inconsistency.c
+++ b/src/auditordb/pg_get_wire_out_inconsistency.c
@@ -1,6 +1,3 @@
-
-
-
/*
This file is part of TALER
Copyright (C) 2024 Taler Systems SA
@@ -63,8 +60,8 @@ struct WireOutInconsistencyContext
*/
static void
wire_out_inconsistency_cb (void *cls,
- PGresult *result,
- unsigned int num_results)
+ PGresult *result,
+ unsigned int num_results)
{
struct WireOutInconsistencyContext *dcc = cls;
struct PostgresClosure *pg = dcc->pg;
@@ -79,10 +76,11 @@ wire_out_inconsistency_cb (void *cls,
GNUNET_PQ_result_spec_uint64 ("row_id", &serial_id),
- GNUNET_PQ_result_spec_auto_from_type("destination_account", &dc.destination_account),
-TALER_PQ_RESULT_SPEC_AMOUNT("expected", &dc.expected),
-TALER_PQ_RESULT_SPEC_AMOUNT("claimed", &dc.claimed),
-GNUNET_PQ_result_spec_bool("suppressed", &dc.suppressed),
+ GNUNET_PQ_result_spec_auto_from_type ("destination_account",
+ &dc.destination_account),
+ TALER_PQ_RESULT_SPEC_AMOUNT ("expected", &dc.expected),
+ TALER_PQ_RESULT_SPEC_AMOUNT ("claimed", &dc.claimed),
+ GNUNET_PQ_result_spec_bool ("suppressed", &dc.suppressed),
GNUNET_PQ_result_spec_end
@@ -139,10 +137,10 @@ TAH_PG_get_wire_out_inconsistency (
"auditor_wire_out_inconsistency_get_desc",
"SELECT"
" row_id,"
-" destination_account,"
-" expected,"
-" claimed,"
-" suppressed"
+ " destination_account,"
+ " expected,"
+ " claimed,"
+ " suppressed"
" FROM auditor_wire_out_inconsistency"
" WHERE (row_id < $1)"
" AND ($2 OR suppressed is false)"
@@ -153,10 +151,10 @@ TAH_PG_get_wire_out_inconsistency (
"auditor_wire_out_inconsistency_get_asc",
"SELECT"
" row_id,"
-" destination_account,"
-" expected,"
-" claimed,"
-" suppressed"
+ " destination_account,"
+ " expected,"
+ " claimed,"
+ " suppressed"
" FROM auditor_wire_out_inconsistency"
" WHERE (row_id > $1)"
" AND ($2 OR suppressed is false)"
@@ -165,8 +163,10 @@ TAH_PG_get_wire_out_inconsistency (
);
qs = GNUNET_PQ_eval_prepared_multi_select (pg->conn,
(limit > 0)
- ? "auditor_wire_out_inconsistency_get_asc"
- : "auditor_wire_out_inconsistency_get_desc",
+ ?
+ "auditor_wire_out_inconsistency_get_asc"
+ :
+ "auditor_wire_out_inconsistency_get_desc",
params,
&wire_out_inconsistency_cb,
&dcc);
@@ -176,6 +176,3 @@ TAH_PG_get_wire_out_inconsistency (
GNUNET_break (GNUNET_DB_STATUS_HARD_ERROR != qs);
return qs;
}
-
-
- \ No newline at end of file
diff --git a/src/auditordb/pg_insert_denomination_pending.c b/src/auditordb/pg_insert_denomination_pending.c
index 70a9981d7..dbea8c6a9 100644
--- a/src/auditordb/pg_insert_denomination_pending.c
+++ b/src/auditordb/pg_insert_denomination_pending.c
@@ -1,6 +1,3 @@
-
-
-
/*
This file is part of TALER
Copyright (C) 2024 Taler Systems SA
@@ -32,13 +29,13 @@ TAH_PG_insert_denomination_pending (
struct PostgresClosure *pg = cls;
struct GNUNET_PQ_QueryParam params[] = {
- GNUNET_PQ_query_param_auto_from_type(&dc->denom_pub_hash),
-TALER_PQ_query_param_amount(pg->conn, &dc->denom_balance),
-TALER_PQ_query_param_amount(pg->conn, &dc->denom_loss),
-GNUNET_PQ_query_param_int64(&dc->num_issued),
-TALER_PQ_query_param_amount(pg->conn, &dc->denom_risk),
-TALER_PQ_query_param_amount(pg->conn, &dc->recoup_loss),
-GNUNET_PQ_query_param_bool(dc->suppressed),
+ GNUNET_PQ_query_param_auto_from_type (&dc->denom_pub_hash),
+ TALER_PQ_query_param_amount (pg->conn, &dc->denom_balance),
+ TALER_PQ_query_param_amount (pg->conn, &dc->denom_loss),
+ GNUNET_PQ_query_param_int64 (&dc->num_issued),
+ TALER_PQ_query_param_amount (pg->conn, &dc->denom_risk),
+ TALER_PQ_query_param_amount (pg->conn, &dc->recoup_loss),
+ GNUNET_PQ_query_param_bool (dc->suppressed),
GNUNET_PQ_query_param_end
@@ -48,17 +45,15 @@ GNUNET_PQ_query_param_bool(dc->suppressed),
"auditor_denomination_pending_insert",
"INSERT INTO auditor_denomination_pending "
"( denom_pub_hash,"
-" denom_balance,"
-" denom_loss,"
-" num_issued,"
-" denom_risk,"
-" recoup_loss,"
-" suppressed"
-") VALUES ($1,$2,$3,$4,$5,$6,$7);"
+ " denom_balance,"
+ " denom_loss,"
+ " num_issued,"
+ " denom_risk,"
+ " recoup_loss,"
+ " suppressed"
+ ") VALUES ($1,$2,$3,$4,$5,$6,$7);"
);
return GNUNET_PQ_eval_prepared_non_select (pg->conn,
"auditor_denomination_pending_insert",
params);
}
-
- \ No newline at end of file
diff --git a/src/auditordb/pg_insert_denominations_without_sigs.c b/src/auditordb/pg_insert_denominations_without_sigs.c
index e22e4ffe9..30d2f0caf 100644
--- a/src/auditordb/pg_insert_denominations_without_sigs.c
+++ b/src/auditordb/pg_insert_denominations_without_sigs.c
@@ -1,6 +1,3 @@
-
-
-
/*
This file is part of TALER
Copyright (C) 2024 Taler Systems SA
@@ -32,11 +29,11 @@ TAH_PG_insert_denominations_without_sigs (
struct PostgresClosure *pg = cls;
struct GNUNET_PQ_QueryParam params[] = {
- GNUNET_PQ_query_param_auto_from_type(&dc->denompub_h),
-TALER_PQ_query_param_amount(pg->conn, &dc->value),
-GNUNET_PQ_query_param_int64(&dc->start_time),
-GNUNET_PQ_query_param_int64(&dc->end_time),
-GNUNET_PQ_query_param_bool(dc->suppressed),
+ GNUNET_PQ_query_param_auto_from_type (&dc->denompub_h),
+ TALER_PQ_query_param_amount (pg->conn, &dc->value),
+ GNUNET_PQ_query_param_int64 (&dc->start_time),
+ GNUNET_PQ_query_param_int64 (&dc->end_time),
+ GNUNET_PQ_query_param_bool (dc->suppressed),
GNUNET_PQ_query_param_end
@@ -46,16 +43,14 @@ GNUNET_PQ_query_param_bool(dc->suppressed),
"auditor_denominations_without_sigs_insert",
"INSERT INTO auditor_denominations_without_sigs "
"( row_id,"
-" denompub_h,"
-" value,"
-" start_time,"
-" end_time,"
-" suppressed"
-") VALUES ($1,$2,$3,$4,$5,$6);"
+ " denompub_h,"
+ " value,"
+ " start_time,"
+ " end_time,"
+ " suppressed"
+ ") VALUES ($1,$2,$3,$4,$5,$6);"
);
return GNUNET_PQ_eval_prepared_non_select (pg->conn,
"auditor_denominations_without_sigs_insert",
params);
}
-
- \ No newline at end of file
diff --git a/src/auditordb/pg_insert_exchange_signkeys.c b/src/auditordb/pg_insert_exchange_signkeys.c
index 09ab0e941..14928e8ae 100644
--- a/src/auditordb/pg_insert_exchange_signkeys.c
+++ b/src/auditordb/pg_insert_exchange_signkeys.c
@@ -1,6 +1,3 @@
-
-
-
/*
This file is part of TALER
Copyright (C) 2024 Taler Systems SA
@@ -32,12 +29,12 @@ TAH_PG_insert_exchange_signkeys (
struct PostgresClosure *pg = cls;
struct GNUNET_PQ_QueryParam params[] = {
- GNUNET_PQ_query_param_auto_from_type(&dc->exchange_pub),
-GNUNET_PQ_query_param_auto_from_type(&dc->master_sig),
-GNUNET_PQ_query_param_int64(&dc->ep_valid_from),
-GNUNET_PQ_query_param_int64(&dc->ep_expire_sign),
-GNUNET_PQ_query_param_int64(&dc->ep_expire_legal),
-GNUNET_PQ_query_param_bool(dc->suppressed),
+ GNUNET_PQ_query_param_auto_from_type (&dc->exchange_pub),
+ GNUNET_PQ_query_param_auto_from_type (&dc->master_sig),
+ GNUNET_PQ_query_param_int64 (&dc->ep_valid_from),
+ GNUNET_PQ_query_param_int64 (&dc->ep_expire_sign),
+ GNUNET_PQ_query_param_int64 (&dc->ep_expire_legal),
+ GNUNET_PQ_query_param_bool (dc->suppressed),
GNUNET_PQ_query_param_end
@@ -47,16 +44,14 @@ GNUNET_PQ_query_param_bool(dc->suppressed),
"auditor_exchange_signkeys_insert",
"INSERT INTO auditor_exchange_signkeys "
"( exchange_pub,"
-" master_sig,"
-" ep_valid_from,"
-" ep_expire_sign,"
-" ep_expire_legal,"
-" suppressed"
-") VALUES ($1,$2,$3,$4,$5,$6);"
+ " master_sig,"
+ " ep_valid_from,"
+ " ep_expire_sign,"
+ " ep_expire_legal,"
+ " suppressed"
+ ") VALUES ($1,$2,$3,$4,$5,$6);"
);
return GNUNET_PQ_eval_prepared_non_select (pg->conn,
"auditor_exchange_signkeys_insert",
params);
}
-
- \ No newline at end of file
diff --git a/src/auditordb/pg_insert_historic_denomination_revenue.c b/src/auditordb/pg_insert_historic_denomination_revenue.c
index c7779c9b3..b46bde680 100644
--- a/src/auditordb/pg_insert_historic_denomination_revenue.c
+++ b/src/auditordb/pg_insert_historic_denomination_revenue.c
@@ -1,6 +1,3 @@
-
-
-
/*
This file is part of TALER
Copyright (C) 2024 Taler Systems SA
@@ -32,11 +29,11 @@ TAH_PG_insert_historic_denomination_revenue (
struct PostgresClosure *pg = cls;
struct GNUNET_PQ_QueryParam params[] = {
- GNUNET_PQ_query_param_auto_from_type(&dc->denom_pub_hash),
-GNUNET_PQ_query_param_int64(&dc->revenue_timestamp),
-TALER_PQ_query_param_amount(pg->conn, &dc->revenue_balance),
-TALER_PQ_query_param_amount(pg->conn, &dc->loss_balance),
-GNUNET_PQ_query_param_bool(dc->suppressed),
+ GNUNET_PQ_query_param_auto_from_type (&dc->denom_pub_hash),
+ GNUNET_PQ_query_param_int64 (&dc->revenue_timestamp),
+ TALER_PQ_query_param_amount (pg->conn, &dc->revenue_balance),
+ TALER_PQ_query_param_amount (pg->conn, &dc->loss_balance),
+ GNUNET_PQ_query_param_bool (dc->suppressed),
GNUNET_PQ_query_param_end
@@ -46,15 +43,13 @@ GNUNET_PQ_query_param_bool(dc->suppressed),
"auditor_historic_denomination_revenue_insert",
"INSERT INTO auditor_historic_denomination_revenue "
"( denom_pub_hash,"
-" revenue_timestamp,"
-" revenue_balance,"
-" loss_balance,"
-" suppressed"
-") VALUES ($1,$2,$3,$4,$5);"
+ " revenue_timestamp,"
+ " revenue_balance,"
+ " loss_balance,"
+ " suppressed"
+ ") VALUES ($1,$2,$3,$4,$5);"
);
return GNUNET_PQ_eval_prepared_non_select (pg->conn,
"auditor_historic_denomination_revenue_insert",
params);
}
-
- \ No newline at end of file
diff --git a/src/auditordb/pg_insert_historic_reserve_summary.c b/src/auditordb/pg_insert_historic_reserve_summary.c
index 420b6223c..7b70984c4 100644
--- a/src/auditordb/pg_insert_historic_reserve_summary.c
+++ b/src/auditordb/pg_insert_historic_reserve_summary.c
@@ -1,6 +1,3 @@
-
-
-
/*
This file is part of TALER
Copyright (C) 2024 Taler Systems SA
@@ -32,10 +29,10 @@ TAH_PG_insert_historic_reserve_summary (
struct PostgresClosure *pg = cls;
struct GNUNET_PQ_QueryParam params[] = {
- GNUNET_PQ_query_param_int64(&dc->start_date),
-GNUNET_PQ_query_param_int64(&dc->end_date),
-TALER_PQ_query_param_amount(pg->conn, &dc->reserve_profits),
-GNUNET_PQ_query_param_bool(dc->suppressed),
+ GNUNET_PQ_query_param_int64 (&dc->start_date),
+ GNUNET_PQ_query_param_int64 (&dc->end_date),
+ TALER_PQ_query_param_amount (pg->conn, &dc->reserve_profits),
+ GNUNET_PQ_query_param_bool (dc->suppressed),
GNUNET_PQ_query_param_end
@@ -45,14 +42,12 @@ GNUNET_PQ_query_param_bool(dc->suppressed),
"auditor_historic_reserve_summary_insert",
"INSERT INTO auditor_historic_reserve_summary "
"( start_date,"
-" end_date,"
-" reserve_profits,"
-" suppressed"
-") VALUES ($1,$2,$3,$4);"
+ " end_date,"
+ " reserve_profits,"
+ " suppressed"
+ ") VALUES ($1,$2,$3,$4);"
);
return GNUNET_PQ_eval_prepared_non_select (pg->conn,
"auditor_historic_reserve_summary_insert",
params);
}
-
- \ No newline at end of file
diff --git a/src/auditordb/pg_insert_misattribution_in_inconsistency.c b/src/auditordb/pg_insert_misattribution_in_inconsistency.c
index 45eb8c004..7d86a6ec1 100644
--- a/src/auditordb/pg_insert_misattribution_in_inconsistency.c
+++ b/src/auditordb/pg_insert_misattribution_in_inconsistency.c
@@ -1,6 +1,3 @@
-
-
-
/*
This file is part of TALER
Copyright (C) 2024 Taler Systems SA
@@ -32,10 +29,10 @@ TAH_PG_insert_misattribution_in_inconsistency (
struct PostgresClosure *pg = cls;
struct GNUNET_PQ_QueryParam params[] = {
- TALER_PQ_query_param_amount(pg->conn, &dc->amount),
-GNUNET_PQ_query_param_int64(&dc->bank_row),
-GNUNET_PQ_query_param_auto_from_type(&dc->reserve_pub),
-GNUNET_PQ_query_param_bool(dc->suppressed),
+ TALER_PQ_query_param_amount (pg->conn, &dc->amount),
+ GNUNET_PQ_query_param_int64 (&dc->bank_row),
+ GNUNET_PQ_query_param_auto_from_type (&dc->reserve_pub),
+ GNUNET_PQ_query_param_bool (dc->suppressed),
GNUNET_PQ_query_param_end
@@ -45,15 +42,13 @@ GNUNET_PQ_query_param_bool(dc->suppressed),
"auditor_misattribution_in_inconsistency_insert",
"INSERT INTO auditor_misattribution_in_inconsistency "
"( row_id,"
-" amount,"
-" bank_row,"
-" reserve_pub,"
-" suppressed"
-") VALUES ($1,$2,$3,$4,$5);"
+ " amount,"
+ " bank_row,"
+ " reserve_pub,"
+ " suppressed"
+ ") VALUES ($1,$2,$3,$4,$5);"
);
return GNUNET_PQ_eval_prepared_non_select (pg->conn,
"auditor_misattribution_in_inconsistency_insert",
params);
}
-
- \ No newline at end of file
diff --git a/src/auditordb/pg_insert_purses.c b/src/auditordb/pg_insert_purses.c
index e32b33bd5..ab7f305d1 100644
--- a/src/auditordb/pg_insert_purses.c
+++ b/src/auditordb/pg_insert_purses.c
@@ -1,6 +1,3 @@
-
-
-
/*
This file is part of TALER
Copyright (C) 2024 Taler Systems SA
@@ -32,12 +29,12 @@ TAH_PG_insert_purses (
struct PostgresClosure *pg = cls;
struct GNUNET_PQ_QueryParam params[] = {
- GNUNET_PQ_query_param_int64(&dc->auditor_purses_rowid),
-GNUNET_PQ_query_param_auto_from_type(&dc->purse_pub),
-TALER_PQ_query_param_amount(pg->conn, &dc->balance),
-TALER_PQ_query_param_amount(pg->conn, &dc->target),
-GNUNET_PQ_query_param_int64(&dc->expiration_date),
-GNUNET_PQ_query_param_bool(dc->suppressed),
+ GNUNET_PQ_query_param_int64 (&dc->auditor_purses_rowid),
+ GNUNET_PQ_query_param_auto_from_type (&dc->purse_pub),
+ TALER_PQ_query_param_amount (pg->conn, &dc->balance),
+ TALER_PQ_query_param_amount (pg->conn, &dc->target),
+ GNUNET_PQ_query_param_int64 (&dc->expiration_date),
+ GNUNET_PQ_query_param_bool (dc->suppressed),
GNUNET_PQ_query_param_end
@@ -47,16 +44,14 @@ GNUNET_PQ_query_param_bool(dc->suppressed),
"auditor_purses_insert",
"INSERT INTO auditor_purses "
"( auditor_purses_rowid,"
-" purse_pub,"
-" balance,"
-" target,"
-" expiration_date,"
-" suppressed"
-") VALUES ($1,$2,$3,$4,$5,$6);"
+ " purse_pub,"
+ " balance,"
+ " target,"
+ " expiration_date,"
+ " suppressed"
+ ") VALUES ($1,$2,$3,$4,$5,$6);"
);
return GNUNET_PQ_eval_prepared_non_select (pg->conn,
"auditor_purses_insert",
params);
}
-
- \ No newline at end of file
diff --git a/src/auditordb/pg_insert_reserve_in_inconsistency.c b/src/auditordb/pg_insert_reserve_in_inconsistency.c
index 0b69f10e9..7090e20df 100644
--- a/src/auditordb/pg_insert_reserve_in_inconsistency.c
+++ b/src/auditordb/pg_insert_reserve_in_inconsistency.c
@@ -1,6 +1,3 @@
-
-
-
/*
This file is part of TALER
Copyright (C) 2024 Taler Systems SA
@@ -32,13 +29,13 @@ TAH_PG_insert_reserve_in_inconsistency (
struct PostgresClosure *pg = cls;
struct GNUNET_PQ_QueryParam params[] = {
- TALER_PQ_query_param_amount(pg->conn, &dc->amount_exchange_expected),
-TALER_PQ_query_param_amount(pg->conn, &dc->amount_wired),
-GNUNET_PQ_query_param_auto_from_type(&dc->reserve_pub),
-GNUNET_PQ_query_param_int64(&dc->timestamp),
-GNUNET_PQ_query_param_auto_from_type(&dc->account),
-GNUNET_PQ_query_param_auto_from_type(&dc->diagnostic),
-GNUNET_PQ_query_param_bool(dc->suppressed),
+ TALER_PQ_query_param_amount (pg->conn, &dc->amount_exchange_expected),
+ TALER_PQ_query_param_amount (pg->conn, &dc->amount_wired),
+ GNUNET_PQ_query_param_auto_from_type (&dc->reserve_pub),
+ GNUNET_PQ_query_param_int64 (&dc->timestamp),
+ GNUNET_PQ_query_param_auto_from_type (&dc->account),
+ GNUNET_PQ_query_param_auto_from_type (&dc->diagnostic),
+ GNUNET_PQ_query_param_bool (dc->suppressed),
GNUNET_PQ_query_param_end
@@ -48,18 +45,16 @@ GNUNET_PQ_query_param_bool(dc->suppressed),
"auditor_reserve_in_inconsistency_insert",
"INSERT INTO auditor_reserve_in_inconsistency "
"( row_id,"
-" amount_exchange_expected,"
-" amount_wired,"
-" reserve_pub,"
-" timestamp,"
-" account,"
-" diagnostic,"
-" suppressed"
-") VALUES ($1,$2,$3,$4,$5,$6,$7,$8);"
+ " amount_exchange_expected,"
+ " amount_wired,"
+ " reserve_pub,"
+ " timestamp,"
+ " account,"
+ " diagnostic,"
+ " suppressed"
+ ") VALUES ($1,$2,$3,$4,$5,$6,$7,$8);"
);
return GNUNET_PQ_eval_prepared_non_select (pg->conn,
"auditor_reserve_in_inconsistency_insert",
params);
}
-
- \ No newline at end of file
diff --git a/src/auditordb/pg_insert_reserve_not_closed_inconsistency.c b/src/auditordb/pg_insert_reserve_not_closed_inconsistency.c
index 6f35e6f77..1a5302ce3 100644
--- a/src/auditordb/pg_insert_reserve_not_closed_inconsistency.c
+++ b/src/auditordb/pg_insert_reserve_not_closed_inconsistency.c
@@ -1,6 +1,3 @@
-
-
-
/*
This file is part of TALER
Copyright (C) 2024 Taler Systems SA
@@ -32,11 +29,11 @@ TAH_PG_insert_reserve_not_closed_inconsistency (
struct PostgresClosure *pg = cls;
struct GNUNET_PQ_QueryParam params[] = {
- GNUNET_PQ_query_param_auto_from_type(&dc->reserve_pub),
-TALER_PQ_query_param_amount(pg->conn, &dc->balance),
-GNUNET_PQ_query_param_int64(&dc->expiration_time),
-GNUNET_PQ_query_param_auto_from_type(&dc->diagnostic),
-GNUNET_PQ_query_param_bool(dc->suppressed),
+ GNUNET_PQ_query_param_auto_from_type (&dc->reserve_pub),
+ TALER_PQ_query_param_amount (pg->conn, &dc->balance),
+ GNUNET_PQ_query_param_int64 (&dc->expiration_time),
+ GNUNET_PQ_query_param_auto_from_type (&dc->diagnostic),
+ GNUNET_PQ_query_param_bool (dc->suppressed),
GNUNET_PQ_query_param_end
@@ -46,16 +43,14 @@ GNUNET_PQ_query_param_bool(dc->suppressed),
"auditor_reserve_not_closed_inconsistency_insert",
"INSERT INTO auditor_reserve_not_closed_inconsistency "
"( row_id,"
-" reserve_pub,"
-" balance,"
-" expiration_time,"
-" diagnostic,"
-" suppressed"
-") VALUES ($1,$2,$3,$4,$5,$6);"
+ " reserve_pub,"
+ " balance,"
+ " expiration_time,"
+ " diagnostic,"
+ " suppressed"
+ ") VALUES ($1,$2,$3,$4,$5,$6);"
);
return GNUNET_PQ_eval_prepared_non_select (pg->conn,
"auditor_reserve_not_closed_inconsistency_insert",
params);
}
-
- \ No newline at end of file
diff --git a/src/auditordb/pg_insert_reserves.c b/src/auditordb/pg_insert_reserves.c
index 3bb73a73e..d7626310e 100644
--- a/src/auditordb/pg_insert_reserves.c
+++ b/src/auditordb/pg_insert_reserves.c
@@ -1,6 +1,3 @@
-
-
-
/*
This file is part of TALER
Copyright (C) 2024 Taler Systems SA
@@ -32,18 +29,18 @@ TAH_PG_insert_reserves (
struct PostgresClosure *pg = cls;
struct GNUNET_PQ_QueryParam params[] = {
- GNUNET_PQ_query_param_int64(&dc->auditor_reserves_rowid),
-GNUNET_PQ_query_param_auto_from_type(&dc->reserve_pub),
-TALER_PQ_query_param_amount(pg->conn, &dc->reserve_balance),
-TALER_PQ_query_param_amount(pg->conn, &dc->reserve_loss),
-TALER_PQ_query_param_amount(pg->conn, &dc->withdraw_fee_balance),
-TALER_PQ_query_param_amount(pg->conn, &dc->close_fee_balance),
-TALER_PQ_query_param_amount(pg->conn, &dc->purse_fee_balance),
-TALER_PQ_query_param_amount(pg->conn, &dc->open_fee_balance),
-TALER_PQ_query_param_amount(pg->conn, &dc->history_fee_balance),
-GNUNET_PQ_query_param_int64(&dc->expiration_date),
-GNUNET_PQ_query_param_string(dc->origin_account),
-GNUNET_PQ_query_param_bool(dc->suppressed),
+ GNUNET_PQ_query_param_int64 (&dc->auditor_reserves_rowid),
+ GNUNET_PQ_query_param_auto_from_type (&dc->reserve_pub),
+ TALER_PQ_query_param_amount (pg->conn, &dc->reserve_balance),
+ TALER_PQ_query_param_amount (pg->conn, &dc->reserve_loss),
+ TALER_PQ_query_param_amount (pg->conn, &dc->withdraw_fee_balance),
+ TALER_PQ_query_param_amount (pg->conn, &dc->close_fee_balance),
+ TALER_PQ_query_param_amount (pg->conn, &dc->purse_fee_balance),
+ TALER_PQ_query_param_amount (pg->conn, &dc->open_fee_balance),
+ TALER_PQ_query_param_amount (pg->conn, &dc->history_fee_balance),
+ GNUNET_PQ_query_param_int64 (&dc->expiration_date),
+ GNUNET_PQ_query_param_string (dc->origin_account),
+ GNUNET_PQ_query_param_bool (dc->suppressed),
GNUNET_PQ_query_param_end
@@ -53,22 +50,20 @@ GNUNET_PQ_query_param_bool(dc->suppressed),
"auditor_reserves_insert",
"INSERT INTO auditor_reserves "
"( auditor_reserves_rowid,"
-" reserve_pub,"
-" reserve_balance,"
-" reserve_loss,"
-" withdraw_fee_balance,"
-" close_fee_balance,"
-" purse_fee_balance,"
-" open_fee_balance,"
-" history_fee_balance,"
-" expiration_date,"
-" origin_account,"
-" suppressed"
-") VALUES ($1,$2,$3,$4,$5,$6,$7,$8,$9,$10,$11,$12);"
+ " reserve_pub,"
+ " reserve_balance,"
+ " reserve_loss,"
+ " withdraw_fee_balance,"
+ " close_fee_balance,"
+ " purse_fee_balance,"
+ " open_fee_balance,"
+ " history_fee_balance,"
+ " expiration_date,"
+ " origin_account,"
+ " suppressed"
+ ") VALUES ($1,$2,$3,$4,$5,$6,$7,$8,$9,$10,$11,$12);"
);
return GNUNET_PQ_eval_prepared_non_select (pg->conn,
"auditor_reserves_insert",
params);
}
-
- \ No newline at end of file
diff --git a/src/auditordb/pg_insert_row_minor_inconsistencies.c b/src/auditordb/pg_insert_row_minor_inconsistencies.c
index c60fdc3c5..2759d4c40 100644
--- a/src/auditordb/pg_insert_row_minor_inconsistencies.c
+++ b/src/auditordb/pg_insert_row_minor_inconsistencies.c
@@ -1,6 +1,3 @@
-
-
-
/*
This file is part of TALER
Copyright (C) 2024 Taler Systems SA
@@ -32,9 +29,9 @@ TAH_PG_insert_row_minor_inconsistencies (
struct PostgresClosure *pg = cls;
struct GNUNET_PQ_QueryParam params[] = {
- GNUNET_PQ_query_param_auto_from_type(&dc->row_table),
-GNUNET_PQ_query_param_auto_from_type(&dc->diagnostic),
-GNUNET_PQ_query_param_bool(dc->suppressed),
+ GNUNET_PQ_query_param_auto_from_type (&dc->row_table),
+ GNUNET_PQ_query_param_auto_from_type (&dc->diagnostic),
+ GNUNET_PQ_query_param_bool (dc->suppressed),
GNUNET_PQ_query_param_end
@@ -44,14 +41,12 @@ GNUNET_PQ_query_param_bool(dc->suppressed),
"auditor_row_minor_inconsistencies_insert",
"INSERT INTO auditor_row_minor_inconsistencies "
"( row_id,"
-" row_table,"
-" diagnostic,"
-" suppressed"
-") VALUES ($1,$2,$3,$4);"
+ " row_table,"
+ " diagnostic,"
+ " suppressed"
+ ") VALUES ($1,$2,$3,$4);"
);
return GNUNET_PQ_eval_prepared_non_select (pg->conn,
"auditor_row_minor_inconsistencies_insert",
params);
}
-
- \ No newline at end of file
diff --git a/src/auditordb/pg_insert_wire_format_inconsistency.c b/src/auditordb/pg_insert_wire_format_inconsistency.c
index 210bcc5e8..fb031d8f3 100644
--- a/src/auditordb/pg_insert_wire_format_inconsistency.c
+++ b/src/auditordb/pg_insert_wire_format_inconsistency.c
@@ -1,6 +1,3 @@
-
-
-
/*
This file is part of TALER
Copyright (C) 2024 Taler Systems SA
@@ -32,10 +29,10 @@ TAH_PG_insert_wire_format_inconsistency (
struct PostgresClosure *pg = cls;
struct GNUNET_PQ_QueryParam params[] = {
- TALER_PQ_query_param_amount(pg->conn, &dc->amount),
-GNUNET_PQ_query_param_int64(&dc->wire_offset),
-GNUNET_PQ_query_param_auto_from_type(&dc->diagnostic),
-GNUNET_PQ_query_param_bool(dc->suppressed),
+ TALER_PQ_query_param_amount (pg->conn, &dc->amount),
+ GNUNET_PQ_query_param_int64 (&dc->wire_offset),
+ GNUNET_PQ_query_param_auto_from_type (&dc->diagnostic),
+ GNUNET_PQ_query_param_bool (dc->suppressed),
GNUNET_PQ_query_param_end
@@ -45,15 +42,13 @@ GNUNET_PQ_query_param_bool(dc->suppressed),
"auditor_wire_format_inconsistency_insert",
"INSERT INTO auditor_wire_format_inconsistency "
"( row_id,"
-" amount,"
-" wire_offset,"
-" diagnostic,"
-" suppressed"
-") VALUES ($1,$2,$3,$4,$5);"
+ " amount,"
+ " wire_offset,"
+ " diagnostic,"
+ " suppressed"
+ ") VALUES ($1,$2,$3,$4,$5);"
);
return GNUNET_PQ_eval_prepared_non_select (pg->conn,
"auditor_wire_format_inconsistency_insert",
params);
}
-
- \ No newline at end of file
diff --git a/src/auditordb/pg_insert_wire_out_inconsistency.c b/src/auditordb/pg_insert_wire_out_inconsistency.c
index ea72a5fc1..aa1021110 100644
--- a/src/auditordb/pg_insert_wire_out_inconsistency.c
+++ b/src/auditordb/pg_insert_wire_out_inconsistency.c
@@ -1,6 +1,3 @@
-
-
-
/*
This file is part of TALER
Copyright (C) 2024 Taler Systems SA
@@ -32,10 +29,10 @@ TAH_PG_insert_wire_out_inconsistency (
struct PostgresClosure *pg = cls;
struct GNUNET_PQ_QueryParam params[] = {
- GNUNET_PQ_query_param_auto_from_type(&dc->destination_account),
-TALER_PQ_query_param_amount(pg->conn, &dc->expected),
-TALER_PQ_query_param_amount(pg->conn, &dc->claimed),
-GNUNET_PQ_query_param_bool(dc->suppressed),
+ GNUNET_PQ_query_param_auto_from_type (&dc->destination_account),
+ TALER_PQ_query_param_amount (pg->conn, &dc->expected),
+ TALER_PQ_query_param_amount (pg->conn, &dc->claimed),
+ GNUNET_PQ_query_param_bool (dc->suppressed),
GNUNET_PQ_query_param_end
@@ -45,15 +42,13 @@ GNUNET_PQ_query_param_bool(dc->suppressed),
"auditor_wire_out_inconsistency_insert",
"INSERT INTO auditor_wire_out_inconsistency "
"( row_id,"
-" destination_account,"
-" expected,"
-" claimed,"
-" suppressed"
-") VALUES ($1,$2,$3,$4,$5);"
+ " destination_account,"
+ " expected,"
+ " claimed,"
+ " suppressed"
+ ") VALUES ($1,$2,$3,$4,$5);"
);
return GNUNET_PQ_eval_prepared_non_select (pg->conn,
"auditor_wire_out_inconsistency_insert",
params);
}
-
- \ No newline at end of file