aboutsummaryrefslogtreecommitdiff
path: root/src/peerinfo
diff options
context:
space:
mode:
authorDavid Barksdale <amatus.amongus@gmail.com>2016-08-18 00:03:29 +0000
committerDavid Barksdale <amatus.amongus@gmail.com>2016-08-18 00:03:29 +0000
commit7f937e3781f36538d9864fa841822eecdaf0bf27 (patch)
tree318eb592dae2bbf59d094f5df140c24a4b6184c9 /src/peerinfo
parent94a717fab18ed25e6bec4b349526212045f6ca70 (diff)
downloadgnunet-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/peerinfo')
-rw-r--r--src/peerinfo/peerinfo_api.c16
-rw-r--r--src/peerinfo/peerinfo_api_notify.c8
2 files changed, 12 insertions, 12 deletions
diff --git a/src/peerinfo/peerinfo_api.c b/src/peerinfo/peerinfo_api.c
index e477186ee..3080fb503 100644
--- a/src/peerinfo/peerinfo_api.c
+++ b/src/peerinfo/peerinfo_api.c
@@ -440,15 +440,15 @@ handle_end_iteration (void *cls,
440static void 440static void
441reconnect (struct GNUNET_PEERINFO_Handle *h) 441reconnect (struct GNUNET_PEERINFO_Handle *h)
442{ 442{
443 GNUNET_MQ_hd_var_size (info,
444 GNUNET_MESSAGE_TYPE_PEERINFO_INFO,
445 struct InfoMessage);
446 GNUNET_MQ_hd_fixed_size (end_iteration,
447 GNUNET_MESSAGE_TYPE_PEERINFO_INFO_END,
448 struct GNUNET_MessageHeader);
449 struct GNUNET_MQ_MessageHandler handlers[] = { 443 struct GNUNET_MQ_MessageHandler handlers[] = {
450 make_info_handler (h), 444 GNUNET_MQ_hd_var_size (info,
451 make_end_iteration_handler (h), 445 GNUNET_MESSAGE_TYPE_PEERINFO_INFO,
446 struct InfoMessage,
447 h),
448 GNUNET_MQ_hd_fixed_size (end_iteration,
449 GNUNET_MESSAGE_TYPE_PEERINFO_INFO_END,
450 struct GNUNET_MessageHeader,
451 h),
452 GNUNET_MQ_handler_end () 452 GNUNET_MQ_handler_end ()
453 }; 453 };
454 454
diff --git a/src/peerinfo/peerinfo_api_notify.c b/src/peerinfo/peerinfo_api_notify.c
index c3dac5064..625cfb8f6 100644
--- a/src/peerinfo/peerinfo_api_notify.c
+++ b/src/peerinfo/peerinfo_api_notify.c
@@ -179,12 +179,12 @@ handle_notification (void *cls,
179static void 179static void
180reconnect (void *cls) 180reconnect (void *cls)
181{ 181{
182 GNUNET_MQ_hd_var_size (notification,
183 GNUNET_MESSAGE_TYPE_PEERINFO_INFO,
184 struct InfoMessage);
185 struct GNUNET_PEERINFO_NotifyContext *nc = cls; 182 struct GNUNET_PEERINFO_NotifyContext *nc = cls;
186 struct GNUNET_MQ_MessageHandler handlers[] = { 183 struct GNUNET_MQ_MessageHandler handlers[] = {
187 make_notification_handler (nc), 184 GNUNET_MQ_hd_var_size (notification,
185 GNUNET_MESSAGE_TYPE_PEERINFO_INFO,
186 struct InfoMessage,
187 nc),
188 GNUNET_MQ_handler_end () 188 GNUNET_MQ_handler_end ()
189 }; 189 };
190 struct GNUNET_MQ_Envelope *env; 190 struct GNUNET_MQ_Envelope *env;