diff options
author | David Barksdale <amatus.amongus@gmail.com> | 2016-08-18 00:03:29 +0000 |
---|---|---|
committer | David Barksdale <amatus.amongus@gmail.com> | 2016-08-18 00:03:29 +0000 |
commit | 7f937e3781f36538d9864fa841822eecdaf0bf27 (patch) | |
tree | 318eb592dae2bbf59d094f5df140c24a4b6184c9 /src/scalarproduct/scalarproduct_api.c | |
parent | 94a717fab18ed25e6bec4b349526212045f6ca70 (diff) | |
download | gnunet-7f937e3781f36538d9864fa841822eecdaf0bf27.tar.gz gnunet-7f937e3781f36538d9864fa841822eecdaf0bf27.zip |
Use statement exprs instead of local function
This change lets us compile with clang again.
Diffstat (limited to 'src/scalarproduct/scalarproduct_api.c')
-rw-r--r-- | src/scalarproduct/scalarproduct_api.c | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/src/scalarproduct/scalarproduct_api.c b/src/scalarproduct/scalarproduct_api.c index 09e06d5a0..5ad64f4be 100644 --- a/src/scalarproduct/scalarproduct_api.c +++ b/src/scalarproduct/scalarproduct_api.c | |||
@@ -230,13 +230,13 @@ GNUNET_SCALARPRODUCT_accept_computation (const struct GNUNET_CONFIGURATION_Handl | |||
230 | GNUNET_SCALARPRODUCT_ContinuationWithStatus cont, | 230 | GNUNET_SCALARPRODUCT_ContinuationWithStatus cont, |
231 | void *cont_cls) | 231 | void *cont_cls) |
232 | { | 232 | { |
233 | GNUNET_MQ_hd_var_size (response, | ||
234 | GNUNET_MESSAGE_TYPE_SCALARPRODUCT_RESULT, | ||
235 | struct ClientResponseMessage); | ||
236 | struct GNUNET_SCALARPRODUCT_ComputationHandle *h | 233 | struct GNUNET_SCALARPRODUCT_ComputationHandle *h |
237 | = GNUNET_new (struct GNUNET_SCALARPRODUCT_ComputationHandle); | 234 | = GNUNET_new (struct GNUNET_SCALARPRODUCT_ComputationHandle); |
238 | struct GNUNET_MQ_MessageHandler handlers[] = { | 235 | struct GNUNET_MQ_MessageHandler handlers[] = { |
239 | make_response_handler (h), | 236 | GNUNET_MQ_hd_var_size (response, |
237 | GNUNET_MESSAGE_TYPE_SCALARPRODUCT_RESULT, | ||
238 | struct ClientResponseMessage, | ||
239 | h), | ||
240 | GNUNET_MQ_handler_end () | 240 | GNUNET_MQ_handler_end () |
241 | }; | 241 | }; |
242 | struct GNUNET_MQ_Envelope *env; | 242 | struct GNUNET_MQ_Envelope *env; |
@@ -388,13 +388,13 @@ GNUNET_SCALARPRODUCT_start_computation (const struct GNUNET_CONFIGURATION_Handle | |||
388 | GNUNET_SCALARPRODUCT_DatumProcessor cont, | 388 | GNUNET_SCALARPRODUCT_DatumProcessor cont, |
389 | void *cont_cls) | 389 | void *cont_cls) |
390 | { | 390 | { |
391 | GNUNET_MQ_hd_var_size (response, | ||
392 | GNUNET_MESSAGE_TYPE_SCALARPRODUCT_RESULT, | ||
393 | struct ClientResponseMessage); | ||
394 | struct GNUNET_SCALARPRODUCT_ComputationHandle *h | 391 | struct GNUNET_SCALARPRODUCT_ComputationHandle *h |
395 | = GNUNET_new (struct GNUNET_SCALARPRODUCT_ComputationHandle); | 392 | = GNUNET_new (struct GNUNET_SCALARPRODUCT_ComputationHandle); |
396 | struct GNUNET_MQ_MessageHandler handlers[] = { | 393 | struct GNUNET_MQ_MessageHandler handlers[] = { |
397 | make_response_handler (h), | 394 | GNUNET_MQ_hd_var_size (response, |
395 | GNUNET_MESSAGE_TYPE_SCALARPRODUCT_RESULT, | ||
396 | struct ClientResponseMessage, | ||
397 | h), | ||
398 | GNUNET_MQ_handler_end () | 398 | GNUNET_MQ_handler_end () |
399 | }; | 399 | }; |
400 | struct GNUNET_MQ_Envelope *env; | 400 | struct GNUNET_MQ_Envelope *env; |