diff options
Diffstat (limited to 'src/exchange/taler-exchange-httpd_management_auditors.c')
| -rw-r--r-- | src/exchange/taler-exchange-httpd_management_auditors.c | 34 | 
1 files changed, 15 insertions, 19 deletions
diff --git a/src/exchange/taler-exchange-httpd_management_auditors.c b/src/exchange/taler-exchange-httpd_management_auditors.c index f69580ec..77e7d865 100644 --- a/src/exchange/taler-exchange-httpd_management_auditors.c +++ b/src/exchange/taler-exchange-httpd_management_auditors.c @@ -164,20 +164,16 @@ TEH_handler_management_auditors (                                     &aac.validity_start),      GNUNET_JSON_spec_end ()    }; -  enum GNUNET_DB_QueryStatus qs;    MHD_RESULT res; - -  { -    enum GNUNET_GenericReturnValue res; - -    res = TALER_MHD_parse_json_data (connection, -                                     root, -                                     spec); -    if (GNUNET_SYSERR == res) -      return MHD_NO; /* hard failure */ -    if (GNUNET_NO == res) -      return MHD_YES; /* failure */ -  } +  enum GNUNET_GenericReturnValue ret; + +  ret = TALER_MHD_parse_json_data (connection, +                                   root, +                                   spec); +  if (GNUNET_SYSERR == ret) +    return MHD_NO;   /* hard failure */ +  if (GNUNET_NO == ret) +    return MHD_YES;   /* failure */    if (GNUNET_OK !=        TALER_exchange_offline_auditor_add_verify (          &aac.auditor_pub, @@ -194,12 +190,12 @@ TEH_handler_management_auditors (        NULL);    } -  qs = TEH_DB_run_transaction (connection, -                               "add auditor", -                               &res, -                               &add_auditor, -                               &aac); -  if (qs < 0) +  ret = TEH_DB_run_transaction (connection, +                                "add auditor", +                                &res, +                                &add_auditor, +                                &aac); +  if (GNUNET_SYSERR == ret)      return res;    return TALER_MHD_reply_static (      connection,  | 
