[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[taler-exchange] branch master updated: -improve error handling
From: |
gnunet |
Subject: |
[taler-exchange] branch master updated: -improve error handling |
Date: |
Mon, 26 Feb 2024 20:35:53 +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 6d2b01d1 -improve error handling
6d2b01d1 is described below
commit 6d2b01d1645a1520099aae9c59ce3b7da99310f4
Author: Christian Grothoff <christian@grothoff.org>
AuthorDate: Mon Feb 26 20:35:50 2024 +0100
-improve error handling
---
src/exchange/taler-exchange-httpd_kyc-check.c | 36 +++++++++++++++------------
src/kyclogic/plugin_kyclogic_oauth2.c | 11 ++++++++
2 files changed, 31 insertions(+), 16 deletions(-)
diff --git a/src/exchange/taler-exchange-httpd_kyc-check.c
b/src/exchange/taler-exchange-httpd_kyc-check.c
index 513b60b7..fe45cd5b 100644
--- a/src/exchange/taler-exchange-httpd_kyc-check.c
+++ b/src/exchange/taler-exchange-httpd_kyc-check.c
@@ -253,22 +253,26 @@ initiate_cb (
{
kyp->hint = GNUNET_strdup (error_msg_hint);
}
- qs = TEH_plugin->update_kyc_process_by_row (
- TEH_plugin->cls,
- kyp->process_row,
- kyp->section_name,
- &kyp->h_payto,
- provider_user_id,
- provider_legitimization_id,
- redirect_url,
- GNUNET_TIME_UNIT_ZERO_ABS);
- if (qs <= 0)
- GNUNET_log (GNUNET_ERROR_TYPE_ERROR,
- "KYC requirement update failed for %s with status %d at
%s:%u\n",
- TALER_B2S (&kyp->h_payto),
- qs,
- __FILE__,
- __LINE__);
+ if ( (TALER_EC_NONE != ec) &&
+ (NULL != redirect_url) )
+ {
+ qs = TEH_plugin->update_kyc_process_by_row (
+ TEH_plugin->cls,
+ kyp->process_row,
+ kyp->section_name,
+ &kyp->h_payto,
+ provider_user_id,
+ provider_legitimization_id,
+ redirect_url,
+ GNUNET_TIME_UNIT_ZERO_ABS);
+ if (qs <= 0)
+ GNUNET_log (GNUNET_ERROR_TYPE_ERROR,
+ "KYC requirement update failed for %s with status %d at
%s:%u\n",
+ TALER_B2S (&kyp->h_payto),
+ qs,
+ __FILE__,
+ __LINE__);
+ }
GNUNET_assert (kyp->suspended);
kyp->suspended = false;
GNUNET_CONTAINER_DLL_remove (kyp_head,
diff --git a/src/kyclogic/plugin_kyclogic_oauth2.c
b/src/kyclogic/plugin_kyclogic_oauth2.c
index 4225f45c..3a1f50bc 100644
--- a/src/kyclogic/plugin_kyclogic_oauth2.c
+++ b/src/kyclogic/plugin_kyclogic_oauth2.c
@@ -611,6 +611,17 @@ handle_curl_setup_finished (void *cls,
ih->job = NULL;
switch (response_code)
{
+ case 0:
+ GNUNET_log (GNUNET_ERROR_TYPE_WARNING,
+ "/setup URL failed to return HTTP response\n");
+ ih->cb (ih->cb_cls,
+ TALER_EC_EXCHANGE_KYC_PROOF_BACKEND_INVALID_RESPONSE,
+ NULL,
+ NULL,
+ NULL,
+ "/setup request to OAuth 2.0 backend returned no response");
+ GNUNET_free (ih);
+ return;
case MHD_HTTP_OK:
{
const char *nonce;
--
To stop receiving notification emails like this one, please contact
gnunet@gnunet.org.
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [taler-exchange] branch master updated: -improve error handling,
gnunet <=