aboutsummaryrefslogtreecommitdiff
path: root/src/reclaim/gnunet-service-reclaim.c
diff options
context:
space:
mode:
authorMartin Schanzenbach <schanzen@gnunet.org>2022-10-23 15:00:54 +0900
committerMartin Schanzenbach <schanzen@gnunet.org>2022-10-23 15:00:54 +0900
commitbb81464ede13b1cba93cd031de466bbc8c18f04f (patch)
tree6fc675d02f89c9611afb371b5291bb0fd86eb59e /src/reclaim/gnunet-service-reclaim.c
parentb391cb1d41ad900385338936b655fc0699a61eca (diff)
downloadgnunet-bb81464ede13b1cba93cd031de466bbc8c18f04f.tar.gz
gnunet-bb81464ede13b1cba93cd031de466bbc8c18f04f.zip
NAMESTORE: Introduce GANA-managed error codes
Diffstat (limited to 'src/reclaim/gnunet-service-reclaim.c')
-rw-r--r--src/reclaim/gnunet-service-reclaim.c26
1 files changed, 13 insertions, 13 deletions
diff --git a/src/reclaim/gnunet-service-reclaim.c b/src/reclaim/gnunet-service-reclaim.c
index 5290621d6..5c484e55d 100644
--- a/src/reclaim/gnunet-service-reclaim.c
+++ b/src/reclaim/gnunet-service-reclaim.c
@@ -970,7 +970,7 @@ handle_consume_ticket_message (void *cls, const struct ConsumeTicketMessage *cm)
970 * @param emsg error message (NULL if success=GNUNET_OK) 970 * @param emsg error message (NULL if success=GNUNET_OK)
971 */ 971 */
972static void 972static void
973attr_store_cont (void *cls, int32_t success, const char *emsg) 973attr_store_cont (void *cls, enum GNUNET_ErrorCode ec)
974{ 974{
975 struct AttributeStoreHandle *ash = cls; 975 struct AttributeStoreHandle *ash = cls;
976 struct GNUNET_MQ_Envelope *env; 976 struct GNUNET_MQ_Envelope *env;
@@ -981,11 +981,11 @@ attr_store_cont (void *cls, int32_t success, const char *emsg)
981 ash->client->store_op_tail, 981 ash->client->store_op_tail,
982 ash); 982 ash);
983 983
984 if (GNUNET_SYSERR == success) 984 if (GNUNET_EC_NONE != ec)
985 { 985 {
986 GNUNET_log (GNUNET_ERROR_TYPE_ERROR, 986 GNUNET_log (GNUNET_ERROR_TYPE_ERROR,
987 "Failed to store attribute %s\n", 987 "Failed to store attribute %s\n",
988 emsg); 988 GNUNET_ErrorCode_get_hint (ec));
989 cleanup_as_handle (ash); 989 cleanup_as_handle (ash);
990 GNUNET_SCHEDULER_add_now (&do_shutdown, NULL); 990 GNUNET_SCHEDULER_add_now (&do_shutdown, NULL);
991 return; 991 return;
@@ -1108,7 +1108,7 @@ handle_attribute_store_message (void *cls,
1108 * @param emsg error message (NULL if success=GNUNET_OK) 1108 * @param emsg error message (NULL if success=GNUNET_OK)
1109 */ 1109 */
1110static void 1110static void
1111cred_store_cont (void *cls, int32_t success, const char *emsg) 1111cred_store_cont (void *cls, enum GNUNET_ErrorCode ec)
1112{ 1112{
1113 struct AttributeStoreHandle *ash = cls; 1113 struct AttributeStoreHandle *ash = cls;
1114 struct GNUNET_MQ_Envelope *env; 1114 struct GNUNET_MQ_Envelope *env;
@@ -1119,11 +1119,11 @@ cred_store_cont (void *cls, int32_t success, const char *emsg)
1119 ash->client->store_op_tail, 1119 ash->client->store_op_tail,
1120 ash); 1120 ash);
1121 1121
1122 if (GNUNET_SYSERR == success) 1122 if (GNUNET_EC_NONE != ec)
1123 { 1123 {
1124 GNUNET_log (GNUNET_ERROR_TYPE_ERROR, 1124 GNUNET_log (GNUNET_ERROR_TYPE_ERROR,
1125 "Failed to store credential: %s\n", 1125 "Failed to store credential: %s\n",
1126 emsg); 1126 GNUNET_ErrorCode_get_hint (ec));
1127 cleanup_as_handle (ash); 1127 cleanup_as_handle (ash);
1128 GNUNET_SCHEDULER_add_now (&do_shutdown, NULL); 1128 GNUNET_SCHEDULER_add_now (&do_shutdown, NULL);
1129 return; 1129 return;
@@ -1395,7 +1395,7 @@ update_tickets (void *cls);
1395 * @param emsg error message (NULL if success=GNUNET_OK) 1395 * @param emsg error message (NULL if success=GNUNET_OK)
1396 */ 1396 */
1397static void 1397static void
1398ticket_updated (void *cls, int32_t success, const char *emsg) 1398ticket_updated (void *cls, enum GNUNET_ErrorCode ec)
1399{ 1399{
1400 struct AttributeDeleteHandle *adh = cls; 1400 struct AttributeDeleteHandle *adh = cls;
1401 1401
@@ -1519,12 +1519,12 @@ static void
1519purge_attributes (void *cls);; 1519purge_attributes (void *cls);;
1520 1520
1521static void 1521static void
1522offending_attr_delete_cont (void *cls, int32_t success, const char *emsg) 1522offending_attr_delete_cont (void *cls, enum GNUNET_ErrorCode ec)
1523{ 1523{
1524 struct AttributeDeleteHandle *adh = cls; 1524 struct AttributeDeleteHandle *adh = cls;
1525 1525
1526 adh->ns_qe = NULL; 1526 adh->ns_qe = NULL;
1527 if (GNUNET_SYSERR == success) 1527 if (GNUNET_EC_NONE != ec)
1528 { 1528 {
1529 GNUNET_log (GNUNET_ERROR_TYPE_ERROR, 1529 GNUNET_log (GNUNET_ERROR_TYPE_ERROR,
1530 "Error deleting attribute %s\n", 1530 "Error deleting attribute %s\n",
@@ -1664,12 +1664,12 @@ start_consistency_update (void *cls)
1664 * @param emsg error message (NULL if success=GNUNET_OK) 1664 * @param emsg error message (NULL if success=GNUNET_OK)
1665 */ 1665 */
1666static void 1666static void
1667attr_delete_cont (void *cls, int32_t success, const char *emsg) 1667attr_delete_cont (void *cls, enum GNUNET_ErrorCode ec)
1668{ 1668{
1669 struct AttributeDeleteHandle *adh = cls; 1669 struct AttributeDeleteHandle *adh = cls;
1670 1670
1671 adh->ns_qe = NULL; 1671 adh->ns_qe = NULL;
1672 if (GNUNET_SYSERR == success) 1672 if (GNUNET_EC_NONE != ec)
1673 { 1673 {
1674 GNUNET_log (GNUNET_ERROR_TYPE_ERROR, 1674 GNUNET_log (GNUNET_ERROR_TYPE_ERROR,
1675 "Error deleting attribute %s\n", 1675 "Error deleting attribute %s\n",
@@ -1755,12 +1755,12 @@ handle_attribute_delete_message (void *cls,
1755 * @param emsg error message (NULL if success=GNUNET_OK) 1755 * @param emsg error message (NULL if success=GNUNET_OK)
1756 */ 1756 */
1757static void 1757static void
1758cred_delete_cont (void *cls, int32_t success, const char *emsg) 1758cred_delete_cont (void *cls, enum GNUNET_ErrorCode ec)
1759{ 1759{
1760 struct AttributeDeleteHandle *adh = cls; 1760 struct AttributeDeleteHandle *adh = cls;
1761 1761
1762 adh->ns_qe = NULL; 1762 adh->ns_qe = NULL;
1763 if (GNUNET_SYSERR == success) 1763 if (GNUNET_EC_NONE != ec)
1764 { 1764 {
1765 GNUNET_log (GNUNET_ERROR_TYPE_ERROR, 1765 GNUNET_log (GNUNET_ERROR_TYPE_ERROR,
1766 "Error deleting credential `%s'\n", 1766 "Error deleting credential `%s'\n",