diff options
author | jospaeth <spaethj@in.tum.de> | 2020-07-22 17:23:53 +0200 |
---|---|---|
committer | jospaeth <spaethj@in.tum.de> | 2020-07-22 17:23:53 +0200 |
commit | 7694804564e41a04e9d6e0909a59ee7ec3b7e627 (patch) | |
tree | e4d0a539e0eec95677f94dba281f5d071d0ff292 /src/include/gnunet_escrow_lib.h | |
parent | 0c87a350df02b1dcaffe615f31a63e92be63aef1 (diff) | |
download | gnunet-7694804564e41a04e9d6e0909a59ee7ec3b7e627.tar.gz gnunet-7694804564e41a04e9d6e0909a59ee7ec3b7e627.zip |
handle escrow operations as dll, clean them up
(not yet finished)
Diffstat (limited to 'src/include/gnunet_escrow_lib.h')
-rw-r--r-- | src/include/gnunet_escrow_lib.h | 31 |
1 files changed, 29 insertions, 2 deletions
diff --git a/src/include/gnunet_escrow_lib.h b/src/include/gnunet_escrow_lib.h index 92bd8697e..388f5a3e1 100644 --- a/src/include/gnunet_escrow_lib.h +++ b/src/include/gnunet_escrow_lib.h | |||
@@ -133,6 +133,16 @@ struct GNUNET_ESCROW_Handle | |||
133 | * Configuration to use. | 133 | * Configuration to use. |
134 | */ | 134 | */ |
135 | const struct GNUNET_CONFIGURATION_Handle *cfg; | 135 | const struct GNUNET_CONFIGURATION_Handle *cfg; |
136 | |||
137 | /** | ||
138 | * Head of active operations. | ||
139 | */ | ||
140 | struct GNUNET_ESCROW_Operation *op_head; | ||
141 | |||
142 | /** | ||
143 | * Tail of active operations. | ||
144 | */ | ||
145 | struct GNUNET_ESCROW_Operation *op_tail; | ||
136 | }; | 146 | }; |
137 | 147 | ||
138 | 148 | ||
@@ -147,9 +157,14 @@ struct GNUNET_ESCROW_Operation | |||
147 | struct GNUNET_ESCROW_Handle *h; | 157 | struct GNUNET_ESCROW_Handle *h; |
148 | 158 | ||
149 | /** | 159 | /** |
150 | * Handle to an identity operation. | 160 | * We keep operations in a DLL. |
161 | */ | ||
162 | struct GNUNET_ESCROW_Operation *next; | ||
163 | |||
164 | /** | ||
165 | * We keep operations in a DLL. | ||
151 | */ | 166 | */ |
152 | struct GNUNET_IDENTITY_Operation *id_op; | 167 | struct GNUNET_ESCROW_Operation *prev; |
153 | 168 | ||
154 | /** | 169 | /** |
155 | * Continuation for a PUT operation. | 170 | * Continuation for a PUT operation. |
@@ -316,6 +331,18 @@ GNUNET_ESCROW_anchor_data_to_string (struct GNUNET_ESCROW_Handle *h, | |||
316 | enum GNUNET_ESCROW_Key_Escrow_Method method); | 331 | enum GNUNET_ESCROW_Key_Escrow_Method method); |
317 | 332 | ||
318 | 333 | ||
334 | /** | ||
335 | * Cancel an escrow operation. Note that the operation MAY still | ||
336 | * be executed; this merely cancels the continuation. | ||
337 | * | ||
338 | * @param op operation to cancel | ||
339 | * @param method the escrow method to use | ||
340 | */ | ||
341 | void | ||
342 | GNUNET_ESCROW_cancel (struct GNUNET_ESCROW_Operation *op, | ||
343 | enum GNUNET_ESCROW_Key_Escrow_Method method); | ||
344 | |||
345 | |||
319 | #if 0 /* keep Emacsens' auto-indent happy */ | 346 | #if 0 /* keep Emacsens' auto-indent happy */ |
320 | { | 347 | { |
321 | #endif | 348 | #endif |