gnunet-svn
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[taler-exchange] branch master updated: -fix misc. compiler warnings


From: gnunet
Subject: [taler-exchange] branch master updated: -fix misc. compiler warnings
Date: Fri, 19 Nov 2021 10:57:30 +0100

This is an automated email from the git hooks/post-receive script.

grothoff pushed a commit to branch master
in repository exchange.

The following commit(s) were added to refs/heads/master by this push:
     new bdaaa0f6 -fix misc. compiler warnings
bdaaa0f6 is described below

commit bdaaa0f6cb8f99168ed9916064a5e4145426480c
Author: Christian Grothoff <christian@grothoff.org>
AuthorDate: Fri Nov 19 10:57:27 2021 +0100

    -fix misc. compiler warnings
---
 src/auditor/taler-auditor-httpd.c              |  3 ++
 src/auditor/taler-auditor-sync.c               |  2 ++
 src/auditor/taler-helper-auditor-coins.c       |  3 ++
 src/bank-lib/fakebank.c                        |  2 ++
 src/exchange-tools/taler-auditor-offline.c     |  5 +++
 src/exchange-tools/taler-exchange-offline.c    |  4 +++
 src/exchange/taler-exchange-httpd.c            |  4 +++
 src/exchange/taler-exchange-httpd_db.c         |  2 +-
 src/exchange/taler-exchange-httpd_keys.c       |  2 ++
 src/exchange/taler-exchange-httpd_kyc-wallet.c |  1 +
 src/include/taler_json_lib.h                   | 11 ++++++
 src/json/json.c                                | 11 ++++++
 src/json/json_helper.c                         | 10 ++++++
 src/lib/exchange_api_deposit.c                 | 12 +++++--
 src/lib/exchange_api_handle.c                  |  1 +
 src/lib/exchange_api_kyc_proof.c               |  2 ++
 src/mhd/mhd_run.c                              |  1 +
 src/pq/pq_query_helper.c                       |  3 ++
 src/pq/pq_result_helper.c                      |  3 ++
 src/sq/sq_query_helper.c                       |  1 +
 src/sq/sq_result_helper.c                      | 14 +++++---
 src/testing/testing_api_cmd_auditor_add.c      | 23 +-----------
 src/testing/testing_api_cmd_auditor_del.c      | 23 +-----------
 src/testing/testing_api_cmd_change_auth.c      | 28 ++-------------
 src/testing/testing_api_cmd_exec_transfer.c    |  2 ++
 src/testing/testing_api_cmd_exec_wirewatch.c   |  2 ++
 src/testing/testing_api_cmd_insert_deposit.c   |  2 ++
 src/testing/testing_api_cmd_oauth.c            | 11 ++++++
 src/testing/testing_api_cmd_rewind.c           |  2 +-
 src/testing/testing_api_cmd_set_wire_fee.c     | 23 +-----------
 src/testing/testing_api_cmd_status.c           |  2 +-
 src/testing/testing_api_cmd_wire_add.c         | 23 +-----------
 src/testing/testing_api_cmd_wire_del.c         | 23 +-----------
 src/util/crypto_wire.c                         | 49 --------------------------
 src/util/taler-exchange-secmod-eddsa.c         |  2 ++
 src/util/taler-exchange-secmod-rsa.c           |  1 +
 src/util/util.c                                |  9 -----
 37 files changed, 118 insertions(+), 204 deletions(-)

diff --git a/src/auditor/taler-auditor-httpd.c 
b/src/auditor/taler-auditor-httpd.c
index 47d61866..a212eddc 100644
--- a/src/auditor/taler-auditor-httpd.c
+++ b/src/auditor/taler-auditor-httpd.c
@@ -410,6 +410,9 @@ run (void *cls,
   enum TALER_MHD_GlobalOptions go;
   int fh;
 
+  (void) cls;
+  (void) args;
+  (void) cfgfile;
   go = TALER_MHD_GO_NONE;
   if (auditor_connection_close)
     go |= TALER_MHD_GO_FORCE_CONNECTION_CLOSE;
diff --git a/src/auditor/taler-auditor-sync.c b/src/auditor/taler-auditor-sync.c
index 0dfaa19a..17c4da46 100644
--- a/src/auditor/taler-auditor-sync.c
+++ b/src/auditor/taler-auditor-sync.c
@@ -310,6 +310,7 @@ do_sync (void *cls)
 {
   static struct GNUNET_TIME_Relative delay;
 
+  (void) cls;
   sync_task = NULL;
   actual_size = 0;
   if (GNUNET_SYSERR ==
@@ -469,6 +470,7 @@ load_config (const char *cfgfile)
 static void
 do_shutdown (void *cls)
 {
+  (void) cls;
   if (NULL != sync_task)
   {
     GNUNET_SCHEDULER_cancel (sync_task);
diff --git a/src/auditor/taler-helper-auditor-coins.c 
b/src/auditor/taler-helper-auditor-coins.c
index 56683e58..f0f0cd25 100644
--- a/src/auditor/taler-helper-auditor-coins.c
+++ b/src/auditor/taler-helper-auditor-coins.c
@@ -1575,6 +1575,7 @@ deposit_cb (void *cls,
   enum GNUNET_DB_QueryStatus qs;
 
   (void) done;
+  (void) exchange_timestamp;
   GNUNET_assert (rowid >= ppc.last_deposit_serial_id); /* should be 
monotonically increasing */
   ppc.last_deposit_serial_id = rowid + 1;
 
@@ -2206,6 +2207,8 @@ check_denomination (
   enum GNUNET_DB_QueryStatus qs;
   struct TALER_AuditorSignatureP auditor_sig;
 
+  (void) cls;
+  (void) denom_pub;
   qs = TALER_ARL_edb->select_auditor_denom_sig (TALER_ARL_edb->cls,
                                                 &issue->denom_hash,
                                                 &TALER_ARL_auditor_pub,
diff --git a/src/bank-lib/fakebank.c b/src/bank-lib/fakebank.c
index 19c5e14f..8a0ba21f 100644
--- a/src/bank-lib/fakebank.c
+++ b/src/bank-lib/fakebank.c
@@ -1181,6 +1181,8 @@ free_account (void *cls,
 {
   struct Account *account = val;
 
+  (void) cls;
+  (void) key;
   GNUNET_assert (NULL == account->lp_head);
   GNUNET_free (account->account_name);
   GNUNET_free (account);
diff --git a/src/exchange-tools/taler-auditor-offline.c 
b/src/exchange-tools/taler-auditor-offline.c
index 74e17efc..5ff713a4 100644
--- a/src/exchange-tools/taler-auditor-offline.c
+++ b/src/exchange-tools/taler-auditor-offline.c
@@ -547,6 +547,7 @@ do_upload (char *const *args)
 {
   char *exchange_url;
 
+  (void) args;
   if (GNUNET_YES == GNUNET_is_zero (&auditor_pub))
   {
     /* private key not available, try configuration for public key */
@@ -657,6 +658,8 @@ keys_cb (
 {
   char *const *args = cls;
 
+  (void) keys;
+  (void) compat;
   switch (hr->http_status)
   {
   case MHD_HTTP_OK:
@@ -1375,6 +1378,8 @@ run (void *cls,
      const char *cfgfile,
      const struct GNUNET_CONFIGURATION_Handle *cfg)
 {
+  (void) cls;
+  (void) cfgfile;
   kcfg = cfg;
   if (GNUNET_OK !=
       TALER_config_get_currency (kcfg,
diff --git a/src/exchange-tools/taler-exchange-offline.c 
b/src/exchange-tools/taler-exchange-offline.c
index e6ef0fc2..117e6284 100644
--- a/src/exchange-tools/taler-exchange-offline.c
+++ b/src/exchange-tools/taler-exchange-offline.c
@@ -1759,6 +1759,7 @@ trigger_upload (const char *exchange_url)
 static void
 do_upload (char *const *args)
 {
+  (void) args;
   if (NULL != in)
   {
     GNUNET_log (GNUNET_ERROR_TYPE_ERROR,
@@ -2264,6 +2265,7 @@ download_cb (void *cls,
 {
   char *const *args = cls;
 
+  (void) keys;
   mgkh = NULL;
   switch (hr->http_status)
   {
@@ -3443,6 +3445,8 @@ run (void *cls,
      const char *cfgfile,
      const struct GNUNET_CONFIGURATION_Handle *cfg)
 {
+  (void) cls;
+  (void) cfgfile;
   kcfg = cfg;
   if (GNUNET_OK !=
       TALER_config_get_currency (kcfg,
diff --git a/src/exchange/taler-exchange-httpd.c 
b/src/exchange/taler-exchange-httpd.c
index c29984e2..386d6089 100644
--- a/src/exchange/taler-exchange-httpd.c
+++ b/src/exchange/taler-exchange-httpd.c
@@ -467,6 +467,7 @@ handler_seed (struct TEH_RequestContext *rc,
   MHD_RESULT ret;
   struct MHD_Response *resp;
 
+  (void) args;
   body = malloc (SEED_SIZE); /* must use malloc(), because MHD will use free() 
*/
   if (NULL == body)
     return MHD_NO;
@@ -1712,6 +1713,9 @@ run (void *cls,
   enum TALER_MHD_GlobalOptions go;
   int fh;
 
+  (void) cls;
+  (void) args;
+  (void ) cfgfile;
   go = TALER_MHD_GO_NONE;
   if (connection_close)
     go |= TALER_MHD_GO_FORCE_CONNECTION_CLOSE;
diff --git a/src/exchange/taler-exchange-httpd_db.c 
b/src/exchange/taler-exchange-httpd_db.c
index 3c693649..1d78fb8e 100644
--- a/src/exchange/taler-exchange-httpd_db.c
+++ b/src/exchange/taler-exchange-httpd_db.c
@@ -182,7 +182,7 @@ TEH_DB_run_transaction (struct MHD_Connection *connection,
     }
     /* make sure callback did not violate invariants! */
     GNUNET_assert ( (NULL == mhd_ret) ||
-                    (-1 == *mhd_ret) );
+                    (-1 == (int) *mhd_ret) );
     if (0 <= qs)
       return GNUNET_OK;
   }
diff --git a/src/exchange/taler-exchange-httpd_keys.c 
b/src/exchange/taler-exchange-httpd_keys.c
index f09f61c0..81c77df2 100644
--- a/src/exchange/taler-exchange-httpd_keys.c
+++ b/src/exchange/taler-exchange-httpd_keys.c
@@ -1238,6 +1238,7 @@ add_sign_key_cb (void *cls,
   struct SignKeyCtx *ctx = cls;
   struct SigningKey *sk = value;
 
+  (void) pid;
   ctx->next_sk_expire =
     GNUNET_TIME_absolute_min (ctx->next_sk_expire,
                               sk->meta.expire_sign);
@@ -2575,6 +2576,7 @@ TEH_keys_management_get_keys_handler (const struct 
TEH_RequestHandler *rh,
   struct TEH_KeyStateHandle *ksh;
   json_t *reply;
 
+  (void) rh;
   ksh = get_key_state (true);
   if (NULL == ksh)
   {
diff --git a/src/exchange/taler-exchange-httpd_kyc-wallet.c 
b/src/exchange/taler-exchange-httpd_kyc-wallet.c
index dcab3dca..3db174bf 100644
--- a/src/exchange/taler-exchange-httpd_kyc-wallet.c
+++ b/src/exchange/taler-exchange-httpd_kyc-wallet.c
@@ -109,6 +109,7 @@ TEH_handler_kyc_wallet (
     .purpose = htonl (TALER_SIGNATURE_WALLET_ACCOUNT_SETUP)
   };
 
+  (void) args;
   ret = TALER_MHD_parse_json_data (rc->connection,
                                    root,
                                    spec);
diff --git a/src/include/taler_json_lib.h b/src/include/taler_json_lib.h
index 26df1f11..73d0c418 100644
--- a/src/include/taler_json_lib.h
+++ b/src/include/taler_json_lib.h
@@ -627,6 +627,17 @@ char *
 TALER_JSON_wire_to_payto (const json_t *wire_s);
 
 
+/**
+ * Hash @a extensions.
+ *
+ * @param extensions contract extensions to hash
+ * @param[out] ech where to write the extension hash
+ */
+void
+TALER_deposit_extension_hash (const json_t *extensions,
+                              struct TALER_ExtensionContractHash *ech);
+
+
 #endif /* TALER_JSON_LIB_H_ */
 
 /* End of taler_json_lib.h */
diff --git a/src/json/json.c b/src/json/json.c
index 2dfabbf9..62dec718 100644
--- a/src/json/json.c
+++ b/src/json/json.c
@@ -837,4 +837,15 @@ TALER_JSON_get_error_code2 (const void *data,
 }
 
 
+void
+TALER_deposit_extension_hash (const json_t *extensions,
+                              struct TALER_ExtensionContractHash *ech)
+{
+  GNUNET_assert (GNUNET_OK ==
+                 dump_and_hash (extensions,
+                                "taler-contract-extensions",
+                                &ech->hash));
+}
+
+
 /* End of json/json.c */
diff --git a/src/json/json_helper.c b/src/json/json_helper.c
index e82fb294..7c01cde0 100644
--- a/src/json/json_helper.c
+++ b/src/json/json_helper.c
@@ -232,6 +232,7 @@ parse_abs_time (void *cls,
   json_t *json_t_ms;
   unsigned long long int tval;
 
+  (void) cls;
   if (! json_is_object (root))
   {
     GNUNET_break_op (0);
@@ -313,6 +314,7 @@ parse_abs_time_nbo (void *cls,
   struct GNUNET_TIME_Absolute a;
   struct GNUNET_JSON_Specification ispec;
 
+  (void) cls;
   ispec = *spec;
   ispec.parser = &parse_abs_time;
   ispec.ptr = &a;
@@ -364,6 +366,7 @@ parse_rel_time (void *cls,
   json_t *json_d_ms;
   unsigned long long int tval;
 
+  (void) cls;
   if (! json_is_object (root))
   {
     GNUNET_break_op (0);
@@ -450,6 +453,7 @@ parse_denom_pub (void *cls,
   const char *emsg;
   unsigned int eline;
 
+  (void) cls;
   if (GNUNET_OK !=
       GNUNET_JSON_parse (root,
                          dspec,
@@ -501,6 +505,7 @@ clean_denom_pub (void *cls,
 {
   struct TALER_DenominationPublicKey *denom_pub = spec->ptr;
 
+  (void) cls;
   TALER_denom_pub_free (denom_pub);
 }
 
@@ -543,6 +548,7 @@ parse_denom_sig (void *cls,
   const char *emsg;
   unsigned int eline;
 
+  (void) cls;
   if (GNUNET_OK !=
       GNUNET_JSON_parse (root,
                          dspec,
@@ -594,6 +600,7 @@ clean_denom_sig (void *cls,
 {
   struct TALER_DenominationSignature *denom_sig = spec->ptr;
 
+  (void) cls;
   TALER_denom_sig_free (denom_sig);
 }
 
@@ -636,6 +643,7 @@ parse_blinded_denom_sig (void *cls,
   const char *emsg;
   unsigned int eline;
 
+  (void) cls;
   if (GNUNET_OK !=
       GNUNET_JSON_parse (root,
                          dspec,
@@ -687,6 +695,7 @@ clean_blinded_denom_sig (void *cls,
 {
   struct TALER_BlindedDenominationSignature *denom_sig = spec->ptr;
 
+  (void) cls;
   TALER_blinded_denom_sig_free (denom_sig);
 }
 
@@ -802,6 +811,7 @@ i18n_cleaner (void *cls,
 {
   struct I18nContext *ctx = cls;
 
+  (void) spec;
   GNUNET_free (ctx->lp);
   GNUNET_free (ctx);
 }
diff --git a/src/lib/exchange_api_deposit.c b/src/lib/exchange_api_deposit.c
index 408601c6..7fc8bb6b 100644
--- a/src/lib/exchange_api_deposit.c
+++ b/src/lib/exchange_api_deposit.c
@@ -476,6 +476,7 @@ verify_signatures (const struct 
TALER_EXCHANGE_DenomPublicKey *dki,
                    const struct TALER_Amount *amount,
                    const struct TALER_MerchantWireHash *h_wire,
                    const struct TALER_PrivateContractHash *h_contract_terms,
+                   const struct TALER_ExtensionContractHash *ech,
                    const struct TALER_CoinSpendPublicKeyP *coin_pub,
                    const struct TALER_DenominationSignature *denom_sig,
                    const struct TALER_DenominationPublicKey *denom_pub,
@@ -490,7 +491,7 @@ verify_signatures (const struct 
TALER_EXCHANGE_DenomPublicKey *dki,
                                    &dki->fee_deposit,
                                    h_wire,
                                    h_contract_terms,
-                                   NULL /* FIXME: h_extensions! */,
+                                   ech,
                                    denom_pub_hash,
                                    timestamp,
                                    merchant_pub,
@@ -513,7 +514,7 @@ verify_signatures (const struct 
TALER_EXCHANGE_DenomPublicKey *dki,
       .coin_pub = *coin_pub,
       .denom_pub_hash = *denom_pub_hash,
       .denom_sig = *denom_sig,
-      .age_commitment_hash = NULL /* FIXME-Oec */
+      .age_commitment_hash = { 0 } /* FIXME-Oec */
     };
 
     if (GNUNET_YES !=
@@ -567,8 +568,12 @@ TALER_EXCHANGE_deposit (
   struct TALER_MerchantWireHash h_wire;
   struct TALER_DenominationHash denom_pub_hash;
   struct TALER_Amount amount_without_fee;
+  struct TALER_ExtensionContractHash ech;
   char arg_str[sizeof (struct TALER_CoinSpendPublicKeyP) * 2 + 32];
 
+  if (NULL != extension_details)
+    TALER_deposit_extension_hash (extension_details,
+                                  &ech);
   {
     char pub_str[sizeof (struct TALER_CoinSpendPublicKeyP) * 2];
     char *end;
@@ -623,6 +628,9 @@ TALER_EXCHANGE_deposit (
                          amount,
                          &h_wire,
                          h_contract_terms,
+                         (NULL != extension_details)
+                         ? &ech
+                         : NULL,
                          coin_pub,
                          denom_sig,
                          denom_pub,
diff --git a/src/lib/exchange_api_handle.c b/src/lib/exchange_api_handle.c
index f2f8b594..4d7c6db1 100644
--- a/src/lib/exchange_api_handle.c
+++ b/src/lib/exchange_api_handle.c
@@ -535,6 +535,7 @@ auditor_version_cb (
 {
   struct TEAH_AuditorListEntry *ale = cls;
 
+  (void) hr;
   if (NULL == vi)
   {
     /* In this case, we don't mark the auditor as 'up' */
diff --git a/src/lib/exchange_api_kyc_proof.c b/src/lib/exchange_api_kyc_proof.c
index f8e84d7c..f2ca24eb 100644
--- a/src/lib/exchange_api_kyc_proof.c
+++ b/src/lib/exchange_api_kyc_proof.c
@@ -89,6 +89,8 @@ handle_kyc_proof_finished (void *cls,
     .http_status = (unsigned int) response_code
   };
 
+  (void) body;
+  (void) body_size;
   kph->job = NULL;
   switch (response_code)
   {
diff --git a/src/mhd/mhd_run.c b/src/mhd/mhd_run.c
index cb073e83..7747358f 100644
--- a/src/mhd/mhd_run.c
+++ b/src/mhd/mhd_run.c
@@ -61,6 +61,7 @@ prepare_daemon (void);
 static void
 run_daemon (void *cls)
 {
+  (void) cls;
   mhd_task = NULL;
   do {
     triggered = false;
diff --git a/src/pq/pq_query_helper.c b/src/pq/pq_query_helper.c
index 43b8374a..78c8af97 100644
--- a/src/pq/pq_query_helper.c
+++ b/src/pq/pq_query_helper.c
@@ -181,6 +181,7 @@ qconv_denom_pub (void *cls,
   void *tbuf;
 
   (void) cls;
+  (void) data_len;
   GNUNET_assert (1 == param_length);
   GNUNET_assert (scratch_length > 0);
   GNUNET_break (NULL == cls);
@@ -270,6 +271,7 @@ qconv_denom_sig (void *cls,
   void *tbuf;
 
   (void) cls;
+  (void) data_len;
   GNUNET_assert (1 == param_length);
   GNUNET_assert (scratch_length > 0);
   GNUNET_break (NULL == cls);
@@ -359,6 +361,7 @@ qconv_blinded_denom_sig (void *cls,
   void *tbuf;
 
   (void) cls;
+  (void) data_len;
   GNUNET_assert (1 == param_length);
   GNUNET_assert (scratch_length > 0);
   GNUNET_break (NULL == cls);
diff --git a/src/pq/pq_result_helper.c b/src/pq/pq_result_helper.c
index ea815a9c..8c9f817b 100644
--- a/src/pq/pq_result_helper.c
+++ b/src/pq/pq_result_helper.c
@@ -520,6 +520,7 @@ extract_denom_pub (void *cls,
   uint32_t be[2];
 
   (void) cls;
+  (void) dst_size;
   fnum = PQfnumber (result,
                     fname);
   if (fnum < 0)
@@ -633,6 +634,7 @@ extract_denom_sig (void *cls,
   uint32_t be[2];
 
   (void) cls;
+  (void) dst_size;
   fnum = PQfnumber (result,
                     fname);
   if (fnum < 0)
@@ -750,6 +752,7 @@ extract_blinded_denom_sig (void *cls,
   uint32_t be[2];
 
   (void) cls;
+  (void) dst_size;
   fnum = PQfnumber (result,
                     fname);
   if (fnum < 0)
diff --git a/src/sq/sq_query_helper.c b/src/sq/sq_query_helper.c
index e9070e14..ad5207e2 100644
--- a/src/sq/sq_query_helper.c
+++ b/src/sq/sq_query_helper.c
@@ -97,6 +97,7 @@ qconv_amount_nbo (void *cls,
   struct TALER_Amount amount_hbo;
 
   (void) cls;
+  (void) data_len;
   TALER_amount_ntoh (&amount_hbo,
                      amount);
   return qconv_amount (cls,
diff --git a/src/sq/sq_result_helper.c b/src/sq/sq_result_helper.c
index bc52913b..7cd8e80b 100644
--- a/src/sq/sq_result_helper.c
+++ b/src/sq/sq_result_helper.c
@@ -113,11 +113,15 @@ extract_amount_nbo (void *cls,
   struct TALER_AmountNBO *amount = dst;
   struct TALER_Amount amount_hbo;
   size_t amount_hbo_size = sizeof (struct TALER_Amount);
-  if (GNUNET_YES != extract_amount (cls,
-                                    result,
-                                    column,
-                                    &amount_hbo_size,
-                                    &amount_hbo))
+
+  (void) cls;
+  (void) dst_size;
+  if (GNUNET_YES !=
+      extract_amount (cls,
+                      result,
+                      column,
+                      &amount_hbo_size,
+                      &amount_hbo))
   {
     GNUNET_break (0);
     return GNUNET_SYSERR;
diff --git a/src/testing/testing_api_cmd_auditor_add.c 
b/src/testing/testing_api_cmd_auditor_add.c
index 2c59f419..e40e1319 100644
--- a/src/testing/testing_api_cmd_auditor_add.c
+++ b/src/testing/testing_api_cmd_auditor_add.c
@@ -168,26 +168,6 @@ auditor_add_cleanup (void *cls,
 }
 
 
-/**
- * Offer internal data from a "auditor_add" CMD, to other commands.
- *
- * @param cls closure.
- * @param[out] ret result.
- * @param trait name of the trait.
- * @param index index number of the object to offer.
- *
- * @return #GNUNET_OK on success.
- */
-static int
-auditor_add_traits (void *cls,
-                    const void **ret,
-                    const char *trait,
-                    unsigned int index)
-{
-  return GNUNET_NO;
-}
-
-
 struct TALER_TESTING_Command
 TALER_TESTING_cmd_auditor_add (const char *label,
                                unsigned int expected_http_status,
@@ -203,8 +183,7 @@ TALER_TESTING_cmd_auditor_add (const char *label,
       .cls = ds,
       .label = label,
       .run = &auditor_add_run,
-      .cleanup = &auditor_add_cleanup,
-      .traits = &auditor_add_traits
+      .cleanup = &auditor_add_cleanup
     };
 
     return cmd;
diff --git a/src/testing/testing_api_cmd_auditor_del.c 
b/src/testing/testing_api_cmd_auditor_del.c
index 71525a10..dc31b72b 100644
--- a/src/testing/testing_api_cmd_auditor_del.c
+++ b/src/testing/testing_api_cmd_auditor_del.c
@@ -165,26 +165,6 @@ auditor_del_cleanup (void *cls,
 }
 
 
-/**
- * Offer internal data from a "auditor_del" CMD, to other commands.
- *
- * @param cls closure.
- * @param[out] ret result.
- * @param trait name of the trait.
- * @param index index number of the object to offer.
- *
- * @return #GNUNET_OK on success.
- */
-static int
-auditor_del_traits (void *cls,
-                    const void **ret,
-                    const char *trait,
-                    unsigned int index)
-{
-  return GNUNET_NO;
-}
-
-
 struct TALER_TESTING_Command
 TALER_TESTING_cmd_auditor_del (const char *label,
                                unsigned int expected_http_status,
@@ -200,8 +180,7 @@ TALER_TESTING_cmd_auditor_del (const char *label,
       .cls = ds,
       .label = label,
       .run = &auditor_del_run,
-      .cleanup = &auditor_del_cleanup,
-      .traits = &auditor_del_traits
+      .cleanup = &auditor_del_cleanup
     };
 
     return cmd;
diff --git a/src/testing/testing_api_cmd_change_auth.c 
b/src/testing/testing_api_cmd_change_auth.c
index fdf5d359..2f0f95b7 100644
--- a/src/testing/testing_api_cmd_change_auth.c
+++ b/src/testing/testing_api_cmd_change_auth.c
@@ -40,30 +40,6 @@ struct AuthchangeState
 };
 
 
-/**
- * No traits to offer, just provide a stub to be called when
- * some CMDs iterates through the list of all the commands.
- *
- * @param cls closure.
- * @param[out] ret result.
- * @param trait name of the trait.
- * @param index index number of the trait to return.
- * @return #GNUNET_OK on success.
- */
-static int
-authchange_traits (void *cls,
-                   const void **ret,
-                   const char *trait,
-                   unsigned int index)
-{
-  (void) cls;
-  (void) ret;
-  (void) trait;
-  (void) index;
-  return GNUNET_NO;
-}
-
-
 /**
  * Run the command.
  *
@@ -78,6 +54,7 @@ authchange_run (void *cls,
 {
   struct AuthchangeState *ss = cls;
 
+  (void) cmd;
   if (NULL != is->ctx)
   {
     GNUNET_CURL_fini (is->ctx);
@@ -142,8 +119,7 @@ TALER_TESTING_cmd_set_authorization (const char *label,
       .cls = ss,
       .label = label,
       .run = &authchange_run,
-      .cleanup = &authchange_cleanup,
-      .traits = &authchange_traits
+      .cleanup = &authchange_cleanup
     };
 
     return cmd;
diff --git a/src/testing/testing_api_cmd_exec_transfer.c 
b/src/testing/testing_api_cmd_exec_transfer.c
index beceec57..f8af443b 100644
--- a/src/testing/testing_api_cmd_exec_transfer.c
+++ b/src/testing/testing_api_cmd_exec_transfer.c
@@ -60,6 +60,7 @@ transfer_run (void *cls,
 {
   struct TransferState *as = cls;
 
+  (void) cmd;
   as->transfer_proc
     = GNUNET_OS_start_process (GNUNET_OS_INHERIT_STD_ALL,
                                NULL, NULL, NULL,
@@ -94,6 +95,7 @@ transfer_cleanup (void *cls,
 {
   struct TransferState *as = cls;
 
+  (void) cmd;
   if (NULL != as->transfer_proc)
   {
     GNUNET_break (0 ==
diff --git a/src/testing/testing_api_cmd_exec_wirewatch.c 
b/src/testing/testing_api_cmd_exec_wirewatch.c
index e4188ac8..cd31688d 100644
--- a/src/testing/testing_api_cmd_exec_wirewatch.c
+++ b/src/testing/testing_api_cmd_exec_wirewatch.c
@@ -61,6 +61,7 @@ wirewatch_run (void *cls,
 {
   struct WirewatchState *ws = cls;
 
+  (void) cmd;
   ws->wirewatch_proc
     = GNUNET_OS_start_process (GNUNET_OS_INHERIT_STD_ALL,
                                NULL, NULL, NULL,
@@ -94,6 +95,7 @@ wirewatch_cleanup (void *cls,
 {
   struct WirewatchState *ws = cls;
 
+  (void) cmd;
   if (NULL != ws->wirewatch_proc)
   {
     GNUNET_break (0 ==
diff --git a/src/testing/testing_api_cmd_insert_deposit.c 
b/src/testing/testing_api_cmd_insert_deposit.c
index 6b5d9d74..0001da22 100644
--- a/src/testing/testing_api_cmd_insert_deposit.c
+++ b/src/testing/testing_api_cmd_insert_deposit.c
@@ -139,6 +139,7 @@ insert_deposit_run (void *cls,
   struct TALER_DenominationPublicKey dpk;
   struct TALER_DenominationPrivateKey denom_priv;
 
+  (void) cmd;
   // prepare and store issue first.
   fake_issue (&issue);
   GNUNET_assert (GNUNET_OK ==
@@ -283,6 +284,7 @@ insert_deposit_cleanup (void *cls,
 {
   struct InsertDepositState *ids = cls;
 
+  (void) cmd;
   GNUNET_free (ids);
 }
 
diff --git a/src/testing/testing_api_cmd_oauth.c 
b/src/testing/testing_api_cmd_oauth.c
index 64cb6c03..9c2fef8e 100644
--- a/src/testing/testing_api_cmd_oauth.c
+++ b/src/testing/testing_api_cmd_oauth.c
@@ -92,6 +92,11 @@ handle_post (void *cls,
 {
   struct RequestCtx *rc = cls;
 
+  (void) kind;
+  (void) filename;
+  (void) content_type;
+  (void) transfer_encoding;
+  (void) off;
   if (0 == strcmp (key,
                    "code"))
     append (&rc->code,
@@ -169,6 +174,8 @@ handler_cb (void *cls,
   unsigned int hc;
   json_t *body;
 
+  (void) cls;
+  (void) version;
   if (0 == strcasecmp (method,
                        MHD_HTTP_METHOD_GET))
   {
@@ -292,6 +299,9 @@ cleanup (void *cls,
 {
   struct RequestCtx *rc = *con_cls;
 
+  (void) cls;
+  (void) connection;
+  (void) toe;
   if (NULL == rc)
     return;
   GNUNET_free (rc->code);
@@ -340,6 +350,7 @@ oauth_cleanup (void *cls,
 {
   struct OAuthState *oas = cls;
 
+  (void) cmd;
   if (NULL != oas->mhd)
   {
     MHD_stop_daemon (oas->mhd);
diff --git a/src/testing/testing_api_cmd_rewind.c 
b/src/testing/testing_api_cmd_rewind.c
index dae45624..93b38d3c 100644
--- a/src/testing/testing_api_cmd_rewind.c
+++ b/src/testing/testing_api_cmd_rewind.c
@@ -163,7 +163,7 @@ rewind_ip_run (void *cls,
         break;
     }
   }
-  if (new_ip > is->ip)
+  if (new_ip > (unsigned int) is->ip)
   {
     /* refuse to jump forward */
     GNUNET_break (0);
diff --git a/src/testing/testing_api_cmd_set_wire_fee.c 
b/src/testing/testing_api_cmd_set_wire_fee.c
index 613e0f71..9b5f6258 100644
--- a/src/testing/testing_api_cmd_set_wire_fee.c
+++ b/src/testing/testing_api_cmd_set_wire_fee.c
@@ -206,26 +206,6 @@ wire_add_cleanup (void *cls,
 }
 
 
-/**
- * Offer internal data from a "wire_add" CMD, to other commands.
- *
- * @param cls closure.
- * @param[out] ret result.
- * @param trait name of the trait.
- * @param index index number of the object to offer.
- *
- * @return #GNUNET_OK on success.
- */
-static int
-wire_add_traits (void *cls,
-                 const void **ret,
-                 const char *trait,
-                 unsigned int index)
-{
-  return GNUNET_NO;
-}
-
-
 struct TALER_TESTING_Command
 TALER_TESTING_cmd_set_wire_fee (const char *label,
                                 const char *wire_method,
@@ -247,8 +227,7 @@ TALER_TESTING_cmd_set_wire_fee (const char *label,
       .cls = ds,
       .label = label,
       .run = &wire_add_run,
-      .cleanup = &wire_add_cleanup,
-      .traits = &wire_add_traits
+      .cleanup = &wire_add_cleanup
     };
 
     return cmd;
diff --git a/src/testing/testing_api_cmd_status.c 
b/src/testing/testing_api_cmd_status.c
index 8fdfa461..1424eb6a 100644
--- a/src/testing/testing_api_cmd_status.c
+++ b/src/testing/testing_api_cmd_status.c
@@ -281,7 +281,7 @@ reserve_status_cb (void *cls,
     memset (found,
             0,
             sizeof (found));
-    for (unsigned int i = 0; i<=is->ip; i++)
+    for (unsigned int i = 0; i<= (unsigned int) is->ip; i++)
     {
       struct TALER_TESTING_Command *cmd = &is->commands[i];
 
diff --git a/src/testing/testing_api_cmd_wire_add.c 
b/src/testing/testing_api_cmd_wire_add.c
index 8d8a3a4f..f36eaa85 100644
--- a/src/testing/testing_api_cmd_wire_add.c
+++ b/src/testing/testing_api_cmd_wire_add.c
@@ -178,26 +178,6 @@ wire_add_cleanup (void *cls,
 }
 
 
-/**
- * Offer internal data from a "wire_add" CMD, to other commands.
- *
- * @param cls closure.
- * @param[out] ret result.
- * @param trait name of the trait.
- * @param index index number of the object to offer.
- *
- * @return #GNUNET_OK on success.
- */
-static int
-wire_add_traits (void *cls,
-                 const void **ret,
-                 const char *trait,
-                 unsigned int index)
-{
-  return GNUNET_NO;
-}
-
-
 struct TALER_TESTING_Command
 TALER_TESTING_cmd_wire_add (const char *label,
                             const char *payto_uri,
@@ -215,8 +195,7 @@ TALER_TESTING_cmd_wire_add (const char *label,
       .cls = ds,
       .label = label,
       .run = &wire_add_run,
-      .cleanup = &wire_add_cleanup,
-      .traits = &wire_add_traits
+      .cleanup = &wire_add_cleanup
     };
 
     return cmd;
diff --git a/src/testing/testing_api_cmd_wire_del.c 
b/src/testing/testing_api_cmd_wire_del.c
index 2a1c9e45..fa8c9bcd 100644
--- a/src/testing/testing_api_cmd_wire_del.c
+++ b/src/testing/testing_api_cmd_wire_del.c
@@ -170,26 +170,6 @@ wire_del_cleanup (void *cls,
 }
 
 
-/**
- * Offer internal data from a "wire_del" CMD, to other commands.
- *
- * @param cls closure.
- * @param[out] ret result.
- * @param trait name of the trait.
- * @param index index number of the object to offer.
- *
- * @return #GNUNET_OK on success.
- */
-static int
-wire_del_traits (void *cls,
-                 const void **ret,
-                 const char *trait,
-                 unsigned int index)
-{
-  return GNUNET_NO;
-}
-
-
 struct TALER_TESTING_Command
 TALER_TESTING_cmd_wire_del (const char *label,
                             const char *payto_uri,
@@ -207,8 +187,7 @@ TALER_TESTING_cmd_wire_del (const char *label,
       .cls = ds,
       .label = label,
       .run = &wire_del_run,
-      .cleanup = &wire_del_cleanup,
-      .traits = &wire_del_traits
+      .cleanup = &wire_del_cleanup
     };
 
     return cmd;
diff --git a/src/util/crypto_wire.c b/src/util/crypto_wire.c
index 616ae410..e1c7d964 100644
--- a/src/util/crypto_wire.c
+++ b/src/util/crypto_wire.c
@@ -23,14 +23,6 @@
 #include "taler_signatures.h"
 
 
-/**
- * Check the signature in @a master_sig.
- *
- * @param payto_uri URL that is signed
- * @param master_pub master public key of the exchange
- * @param master_sig signature of the exchange
- * @return #GNUNET_OK if signature is valid
- */
 enum GNUNET_GenericReturnValue
 TALER_exchange_wire_signature_check (
   const char *payto_uri,
@@ -51,13 +43,6 @@ TALER_exchange_wire_signature_check (
 }
 
 
-/**
- * Create a signed wire statement for the given account.
- *
- * @param payto_uri account specification
- * @param master_priv private key to sign with
- * @param[out] master_sig where to write the signature
- */
 void
 TALER_exchange_wire_signature_make (
   const char *payto_uri,
@@ -77,15 +62,6 @@ TALER_exchange_wire_signature_make (
 }
 
 
-/**
- * Compute the hash of the given wire details.   The resulting
- * @a hc is what will be put into the contract between customer
- * and merchant for signing by both parties.
- *
- * @param payto_uri bank account
- * @param salt salt used to eliminate brute-force inversion
- * @param[out] hc set to the hash
- */
 void
 TALER_merchant_wire_signature_hash (const char *payto_uri,
                                     const struct TALER_WireSalt *salt,
@@ -104,23 +80,6 @@ TALER_merchant_wire_signature_hash (const char *payto_uri,
 }
 
 
-/**
- * Check the signature in @a merch_sig.
- * (Not yet used anywhere.)
- *
- * Expected to be used if/when we get @a merch_pub signed via
- * X.509 *and* have a way for the WebEx wallet to check that the
- * @a merch_pub provided matches that of the X.509 certificate
- * from the Web site. Until then, @a merch_pub cannto be
- * validated (no PKI), and hence there is no point in checking
- * these signatures. (See #5129 and #3946).
- *
- * @param payto_uri URL that is signed
- * @param salt the salt used to salt the @a payto_uri when hashing
- * @param merch_pub master public key of the merchant
- * @param merch_sig signature of the merchant
- * @return #GNUNET_OK if signature is valid
- */
 enum GNUNET_GenericReturnValue
 TALER_merchant_wire_signature_check (
   const char *payto_uri,
@@ -143,14 +102,6 @@ TALER_merchant_wire_signature_check (
 }
 
 
-/**
- * Create a signed wire statement for the given account. (Not yet used 
anywhere.)
- *
- * @param payto_uri account specification
- * @param salt the salt used to salt the @a payto_uri when hashing
- * @param merch_priv private key to sign with
- * @param[out] merch_sig where to write the signature
- */
 void
 TALER_merchant_wire_signature_make (
   const char *payto_uri,
diff --git a/src/util/taler-exchange-secmod-eddsa.c 
b/src/util/taler-exchange-secmod-eddsa.c
index 3b7ee3de..a231c9f9 100644
--- a/src/util/taler-exchange-secmod-eddsa.c
+++ b/src/util/taler-exchange-secmod-eddsa.c
@@ -419,6 +419,7 @@ handle_revoke_request (struct TES_Client *client,
   struct Key *key;
   struct Key *nkey;
 
+  (void) client;
   key = NULL;
   GNUNET_assert (0 == pthread_mutex_lock (&keys_lock));
   for (struct Key *pos = keys_head;
@@ -832,6 +833,7 @@ import_key (void *cls,
   int fd;
   struct stat sbuf;
 
+  (void) cls;
   {
     struct stat lsbuf;
 
diff --git a/src/util/taler-exchange-secmod-rsa.c 
b/src/util/taler-exchange-secmod-rsa.c
index 49121c70..1a87c4cc 100644
--- a/src/util/taler-exchange-secmod-rsa.c
+++ b/src/util/taler-exchange-secmod-rsa.c
@@ -561,6 +561,7 @@ handle_revoke_request (struct TES_Client *client,
   struct DenominationKey *ndk;
   struct Denomination *denom;
 
+  (void) client;
   GNUNET_assert (0 == pthread_mutex_lock (&keys_lock));
   dk = GNUNET_CONTAINER_multihashmap_get (keys,
                                           &rr->h_rsa.hash);
diff --git a/src/util/util.c b/src/util/util.c
index 19924b89..274dad3c 100644
--- a/src/util/util.c
+++ b/src/util/util.c
@@ -24,15 +24,6 @@
 #include "taler_util.h"
 
 
-/**
- * Convert a buffer to an 8-character string representative of the
- * contents. This is used for logging binary data when debugging.
- *
- * @param buf buffer to log
- * @param buf_size number of bytes in @a buf
- * @return text representation of buf, valid until next
- *         call to this function
- */
 const char *
 TALER_b2s (const void *buf,
            size_t buf_size)

-- 
To stop receiving notification emails like this one, please contact
gnunet@gnunet.org.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]