LCOV - code coverage report
Current view: top level - auditordb - pg_helper.c (source / functions) Hit Total Coverage
Test: coverage.info Lines: 4 6 66.7 %
Date: 2025-06-05 21:03:14 Functions: 1 1 100.0 %

          Line data    Source code
       1             : /*
       2             :   This file is part of TALER
       3             :   Copyright (C) 2015, 2016 Taler Systems SA
       4             : 
       5             :   TALER is free software; you can redistribute it and/or modify it under the
       6             :   terms of the GNU General Public License as published by the Free Software
       7             :   Foundation; either version 3, or (at your option) any later version.
       8             : 
       9             :   TALER is distributed in the hope that it will be useful, but WITHOUT ANY
      10             :   WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR
      11             :   A PARTICULAR PURPOSE.  See the GNU General Public License for more details.
      12             : 
      13             :   You should have received a copy of the GNU General Public License along with
      14             :   TALER; see the file COPYING.  If not, see <http://www.gnu.org/licenses/>
      15             : */
      16             : /**
      17             :  * @file auditordb/auditordb_plugin.c
      18             :  * @brief Logic to load database plugin
      19             :  * @author Christian Grothoff
      20             :  * @author Sree Harsha Totakura <sreeharsha@totakura.in>
      21             :  */
      22             : #include "platform.h"
      23             : #include "taler_auditordb_plugin.h"
      24             : #include <ltdl.h>
      25             : #include "pg_helper.h"
      26             : 
      27             : 
      28             : const char *
      29          81 : TAH_PG_get_deletable_suppressable_table_name (enum
      30             :                                               TALER_AUDITORDB_DeletableSuppressableTables
      31             :                                               table)
      32             : {
      33          81 :   const char *tables[] = {
      34             :     "auditor_amount_arithmetic_inconsistency",
      35             :     "auditor_closure_lags",
      36             :     "auditor_progress",
      37             :     "auditor_bad_sig_losses",
      38             :     "auditor_coin_inconsistency",
      39             :     "auditor_denomination_key_validity_withdraw_inconsistency",
      40             :     "auditor_denomination_pending",
      41             :     "auditor_denomination_without_sig",
      42             :     "auditor_deposit_confirmations",
      43             :     "auditor_emergency",
      44             :     "auditor_emergency_by_count",
      45             :     "auditor_fee_time_inconsistency",
      46             :     "auditor_misattribution_in_inconsistency",
      47             :     "auditor_purse_not_closed_inconsistency",
      48             :     "auditor_refreshes_haning",
      49             :     "auditor_reserve_balance_insufficient_inconsistency",
      50             :     "auditor_reserve_balance_summary_wrong_inconsistency",
      51             :     "auditor_reserve_in_inconsistency",
      52             :     "auditor_reserve_not_closed_inconsistency",
      53             :     "auditor_row_inconsistency",
      54             :     "auditor_row_minor_inconsistency",
      55             :     "auditor_wire_format_inconsistency",
      56             :     "auditor_wire_out_inconsistency",
      57             :     NULL,
      58             :   };
      59             : 
      60          81 :   if ( (table < 0) ||
      61             :        (table >= TALER_AUDITORDB_DELETABLESUPPRESSABLE_TABLES_MAX))
      62             :   {
      63           0 :     GNUNET_break (0);
      64           0 :     return NULL;
      65             :   }
      66          81 :   return tables[table];
      67             : }

Generated by: LCOV version 1.16