diff options
author | Martin Schanzenbach <schanzen@gnunet.org> | 2022-10-23 15:00:54 +0900 |
---|---|---|
committer | Martin Schanzenbach <schanzen@gnunet.org> | 2022-10-23 15:00:54 +0900 |
commit | bb81464ede13b1cba93cd031de466bbc8c18f04f (patch) | |
tree | 6fc675d02f89c9611afb371b5291bb0fd86eb59e /src/namestore/namestore.h | |
parent | b391cb1d41ad900385338936b655fc0699a61eca (diff) | |
download | gnunet-bb81464ede13b1cba93cd031de466bbc8c18f04f.tar.gz gnunet-bb81464ede13b1cba93cd031de466bbc8c18f04f.zip |
NAMESTORE: Introduce GANA-managed error codes
Diffstat (limited to 'src/namestore/namestore.h')
-rw-r--r-- | src/namestore/namestore.h | 37 |
1 files changed, 9 insertions, 28 deletions
diff --git a/src/namestore/namestore.h b/src/namestore/namestore.h index ea35269a4..37c1576bc 100644 --- a/src/namestore/namestore.h +++ b/src/namestore/namestore.h | |||
@@ -117,23 +117,10 @@ struct RecordStoreResponseMessage | |||
117 | struct GNUNET_NAMESTORE_Header gns_header; | 117 | struct GNUNET_NAMESTORE_Header gns_header; |
118 | 118 | ||
119 | /** | 119 | /** |
120 | * #GNUNET_SYSERR on failure, #GNUNET_OK on success | 120 | * GNUNET_ErrorCode |
121 | */ | 121 | */ |
122 | int32_t op_result GNUNET_PACKED; | 122 | uint32_t ec GNUNET_PACKED; |
123 | 123 | ||
124 | /** | ||
125 | * Error message length | ||
126 | */ | ||
127 | uint16_t emsg_len GNUNET_PACKED; | ||
128 | |||
129 | /** | ||
130 | * Reserved for alignment. | ||
131 | */ | ||
132 | uint16_t reserved GNUNET_PACKED; | ||
133 | |||
134 | /** | ||
135 | * Followed by error message | ||
136 | */ | ||
137 | }; | 124 | }; |
138 | 125 | ||
139 | 126 | ||
@@ -264,10 +251,12 @@ struct ZoneToNameResponseMessage | |||
264 | uint16_t rd_count GNUNET_PACKED; | 251 | uint16_t rd_count GNUNET_PACKED; |
265 | 252 | ||
266 | /** | 253 | /** |
267 | * result in NBO: #GNUNET_OK on success, #GNUNET_NO if there were no | 254 | * result in NBO: #GNUNET_EC_NONE on success, |
268 | * results, #GNUNET_SYSERR on error | 255 | * #GNUNET_EC_NAMESTORE_NO_RESULTS if there were no |
256 | * results. | ||
257 | * Other error messages on error. | ||
269 | */ | 258 | */ |
270 | int16_t res GNUNET_PACKED; | 259 | int32_t ec GNUNET_PACKED; |
271 | 260 | ||
272 | /** | 261 | /** |
273 | * The private key of the zone that contained the name. | 262 | * The private key of the zone that contained the name. |
@@ -361,18 +350,10 @@ struct TxControlResultMessage | |||
361 | struct GNUNET_NAMESTORE_Header gns_header; | 350 | struct GNUNET_NAMESTORE_Header gns_header; |
362 | 351 | ||
363 | /** | 352 | /** |
364 | * The type of control message to send | 353 | * Of type GNUNET_ErrorCode |
365 | */ | ||
366 | uint16_t control GNUNET_PACKED; | ||
367 | |||
368 | /** | ||
369 | * Of type GNUNET_GenericReturnValue | ||
370 | */ | 354 | */ |
371 | uint16_t success GNUNET_PACKED; | 355 | uint32_t ec GNUNET_PACKED; |
372 | 356 | ||
373 | /* followed by: | ||
374 | * an error message if status != ntohs(GNUNET_OK) | ||
375 | */ | ||
376 | }; | 357 | }; |
377 | 358 | ||
378 | 359 | ||