diff options
author | ng0 <ng0@n0.is> | 2019-09-08 12:33:09 +0000 |
---|---|---|
committer | ng0 <ng0@n0.is> | 2019-09-08 12:33:09 +0000 |
commit | d41ed82a4ea0cc8e1674b6d5d2c49fd6462610bb (patch) | |
tree | 9efd18ea7d425652085ed0bd5e8e45604bc5f6b9 /src/include/gnunet_transport_service.h | |
parent | a0fce305c565c0937d917a92712f15e9c5736260 (diff) | |
download | gnunet-d41ed82a4ea0cc8e1674b6d5d2c49fd6462610bb.tar.gz gnunet-d41ed82a4ea0cc8e1674b6d5d2c49fd6462610bb.zip |
uncrustify as demanded.
Diffstat (limited to 'src/include/gnunet_transport_service.h')
-rw-r--r-- | src/include/gnunet_transport_service.h | 72 |
1 files changed, 33 insertions, 39 deletions
diff --git a/src/include/gnunet_transport_service.h b/src/include/gnunet_transport_service.h index 80949b417..735e216e8 100644 --- a/src/include/gnunet_transport_service.h +++ b/src/include/gnunet_transport_service.h | |||
@@ -16,7 +16,7 @@ | |||
16 | along with this program. If not, see <http://www.gnu.org/licenses/>. | 16 | along with this program. If not, see <http://www.gnu.org/licenses/>. |
17 | 17 | ||
18 | SPDX-License-Identifier: AGPL3.0-or-later | 18 | SPDX-License-Identifier: AGPL3.0-or-later |
19 | */ | 19 | */ |
20 | 20 | ||
21 | /** | 21 | /** |
22 | * @author Christian Grothoff | 22 | * @author Christian Grothoff |
@@ -75,10 +75,10 @@ struct GNUNET_TRANSPORT_OfferHelloHandle; | |||
75 | * | 75 | * |
76 | */ | 76 | */ |
77 | struct GNUNET_TRANSPORT_OfferHelloHandle * | 77 | struct GNUNET_TRANSPORT_OfferHelloHandle * |
78 | GNUNET_TRANSPORT_offer_hello (const struct GNUNET_CONFIGURATION_Handle *cfg, | 78 | GNUNET_TRANSPORT_offer_hello(const struct GNUNET_CONFIGURATION_Handle *cfg, |
79 | const struct GNUNET_MessageHeader *hello, | 79 | const struct GNUNET_MessageHeader *hello, |
80 | GNUNET_SCHEDULER_TaskCallback cont, | 80 | GNUNET_SCHEDULER_TaskCallback cont, |
81 | void *cont_cls); | 81 | void *cont_cls); |
82 | 82 | ||
83 | 83 | ||
84 | /** | 84 | /** |
@@ -87,7 +87,7 @@ GNUNET_TRANSPORT_offer_hello (const struct GNUNET_CONFIGURATION_Handle *cfg, | |||
87 | * @param ohh the `struct GNUNET_TRANSPORT_OfferHelloHandle` to cancel | 87 | * @param ohh the `struct GNUNET_TRANSPORT_OfferHelloHandle` to cancel |
88 | */ | 88 | */ |
89 | void | 89 | void |
90 | GNUNET_TRANSPORT_offer_hello_cancel ( | 90 | GNUNET_TRANSPORT_offer_hello_cancel( |
91 | struct GNUNET_TRANSPORT_OfferHelloHandle *ohh); | 91 | struct GNUNET_TRANSPORT_OfferHelloHandle *ohh); |
92 | 92 | ||
93 | 93 | ||
@@ -133,7 +133,7 @@ typedef void (*GNUNET_TRANSPORT_AddressToStringCallback) (void *cls, | |||
133 | * @return handle to cancel the operation, NULL on error | 133 | * @return handle to cancel the operation, NULL on error |
134 | */ | 134 | */ |
135 | struct GNUNET_TRANSPORT_AddressToStringContext * | 135 | struct GNUNET_TRANSPORT_AddressToStringContext * |
136 | GNUNET_TRANSPORT_address_to_string ( | 136 | GNUNET_TRANSPORT_address_to_string( |
137 | const struct GNUNET_CONFIGURATION_Handle *cfg, | 137 | const struct GNUNET_CONFIGURATION_Handle *cfg, |
138 | const struct GNUNET_HELLO_Address *address, | 138 | const struct GNUNET_HELLO_Address *address, |
139 | int numeric, | 139 | int numeric, |
@@ -148,7 +148,7 @@ GNUNET_TRANSPORT_address_to_string ( | |||
148 | * @param alc the context handle | 148 | * @param alc the context handle |
149 | */ | 149 | */ |
150 | void | 150 | void |
151 | GNUNET_TRANSPORT_address_to_string_cancel ( | 151 | GNUNET_TRANSPORT_address_to_string_cancel( |
152 | struct GNUNET_TRANSPORT_AddressToStringContext *alc); | 152 | struct GNUNET_TRANSPORT_AddressToStringContext *alc); |
153 | 153 | ||
154 | 154 | ||
@@ -211,8 +211,7 @@ GNUNET_TRANSPORT_address_to_string_cancel ( | |||
211 | * to 0). | 211 | * to 0). |
212 | * | 212 | * |
213 | */ | 213 | */ |
214 | enum GNUNET_TRANSPORT_PeerState | 214 | enum GNUNET_TRANSPORT_PeerState { |
215 | { | ||
216 | /** | 215 | /** |
217 | * Fresh peer or completely disconnected | 216 | * Fresh peer or completely disconnected |
218 | */ | 217 | */ |
@@ -289,7 +288,7 @@ enum GNUNET_TRANSPORT_PeerState | |||
289 | * @param state the state | 288 | * @param state the state |
290 | */ | 289 | */ |
291 | const char * | 290 | const char * |
292 | GNUNET_TRANSPORT_ps2s (enum GNUNET_TRANSPORT_PeerState state); | 291 | GNUNET_TRANSPORT_ps2s(enum GNUNET_TRANSPORT_PeerState state); |
293 | 292 | ||
294 | 293 | ||
295 | /** | 294 | /** |
@@ -299,7 +298,7 @@ GNUNET_TRANSPORT_ps2s (enum GNUNET_TRANSPORT_PeerState state); | |||
299 | * @return #GNUNET_YES or #GNUNET_NO | 298 | * @return #GNUNET_YES or #GNUNET_NO |
300 | */ | 299 | */ |
301 | int | 300 | int |
302 | GNUNET_TRANSPORT_is_connected (enum GNUNET_TRANSPORT_PeerState state); | 301 | GNUNET_TRANSPORT_is_connected(enum GNUNET_TRANSPORT_PeerState state); |
303 | 302 | ||
304 | 303 | ||
305 | /** | 304 | /** |
@@ -361,7 +360,7 @@ typedef void (*GNUNET_TRANSPORT_PeerIterateCallback) ( | |||
361 | * @param peer_callback_cls closure for @a peer_callback | 360 | * @param peer_callback_cls closure for @a peer_callback |
362 | */ | 361 | */ |
363 | struct GNUNET_TRANSPORT_PeerMonitoringContext * | 362 | struct GNUNET_TRANSPORT_PeerMonitoringContext * |
364 | GNUNET_TRANSPORT_monitor_peers ( | 363 | GNUNET_TRANSPORT_monitor_peers( |
365 | const struct GNUNET_CONFIGURATION_Handle *cfg, | 364 | const struct GNUNET_CONFIGURATION_Handle *cfg, |
366 | const struct GNUNET_PeerIdentity *peer, | 365 | const struct GNUNET_PeerIdentity *peer, |
367 | int one_shot, | 366 | int one_shot, |
@@ -375,7 +374,7 @@ GNUNET_TRANSPORT_monitor_peers ( | |||
375 | * @param pic handle for the request to cancel | 374 | * @param pic handle for the request to cancel |
376 | */ | 375 | */ |
377 | void | 376 | void |
378 | GNUNET_TRANSPORT_monitor_peers_cancel ( | 377 | GNUNET_TRANSPORT_monitor_peers_cancel( |
379 | struct GNUNET_TRANSPORT_PeerMonitoringContext *pic); | 378 | struct GNUNET_TRANSPORT_PeerMonitoringContext *pic); |
380 | 379 | ||
381 | 380 | ||
@@ -414,9 +413,9 @@ typedef int (*GNUNET_TRANSPORT_BlacklistCallback) ( | |||
414 | * @return NULL on error, otherwise handle for cancellation | 413 | * @return NULL on error, otherwise handle for cancellation |
415 | */ | 414 | */ |
416 | struct GNUNET_TRANSPORT_Blacklist * | 415 | struct GNUNET_TRANSPORT_Blacklist * |
417 | GNUNET_TRANSPORT_blacklist (const struct GNUNET_CONFIGURATION_Handle *cfg, | 416 | GNUNET_TRANSPORT_blacklist(const struct GNUNET_CONFIGURATION_Handle *cfg, |
418 | GNUNET_TRANSPORT_BlacklistCallback cb, | 417 | GNUNET_TRANSPORT_BlacklistCallback cb, |
419 | void *cb_cls); | 418 | void *cb_cls); |
420 | 419 | ||
421 | 420 | ||
422 | /** | 421 | /** |
@@ -426,7 +425,7 @@ GNUNET_TRANSPORT_blacklist (const struct GNUNET_CONFIGURATION_Handle *cfg, | |||
426 | * @param br handle of the request that is to be cancelled | 425 | * @param br handle of the request that is to be cancelled |
427 | */ | 426 | */ |
428 | void | 427 | void |
429 | GNUNET_TRANSPORT_blacklist_cancel (struct GNUNET_TRANSPORT_Blacklist *br); | 428 | GNUNET_TRANSPORT_blacklist_cancel(struct GNUNET_TRANSPORT_Blacklist *br); |
430 | 429 | ||
431 | 430 | ||
432 | /** | 431 | /** |
@@ -444,9 +443,7 @@ struct GNUNET_TRANSPORT_PluginSession; | |||
444 | /** | 443 | /** |
445 | * Possible states of a session in a plugin. | 444 | * Possible states of a session in a plugin. |
446 | */ | 445 | */ |
447 | enum GNUNET_TRANSPORT_SessionState | 446 | enum GNUNET_TRANSPORT_SessionState { |
448 | { | ||
449 | |||
450 | /** | 447 | /** |
451 | * The session was created (first call for each session object). | 448 | * The session was created (first call for each session object). |
452 | */ | 449 | */ |
@@ -473,16 +470,13 @@ enum GNUNET_TRANSPORT_SessionState | |||
473 | * Last call for each session object. | 470 | * Last call for each session object. |
474 | */ | 471 | */ |
475 | GNUNET_TRANSPORT_SS_DONE | 472 | GNUNET_TRANSPORT_SS_DONE |
476 | |||
477 | }; | 473 | }; |
478 | 474 | ||
479 | 475 | ||
480 | /** | 476 | /** |
481 | * Information about a plugin's session. | 477 | * Information about a plugin's session. |
482 | */ | 478 | */ |
483 | struct GNUNET_TRANSPORT_SessionInfo | 479 | struct GNUNET_TRANSPORT_SessionInfo { |
484 | { | ||
485 | |||
486 | /** | 480 | /** |
487 | * New state of the session. | 481 | * New state of the session. |
488 | */ | 482 | */ |
@@ -561,9 +555,9 @@ typedef void (*GNUNET_TRANSPORT_SessionMonitorCallback) ( | |||
561 | * @return NULL on error, otherwise handle for cancellation | 555 | * @return NULL on error, otherwise handle for cancellation |
562 | */ | 556 | */ |
563 | struct GNUNET_TRANSPORT_PluginMonitor * | 557 | struct GNUNET_TRANSPORT_PluginMonitor * |
564 | GNUNET_TRANSPORT_monitor_plugins (const struct GNUNET_CONFIGURATION_Handle *cfg, | 558 | GNUNET_TRANSPORT_monitor_plugins(const struct GNUNET_CONFIGURATION_Handle *cfg, |
565 | GNUNET_TRANSPORT_SessionMonitorCallback cb, | 559 | GNUNET_TRANSPORT_SessionMonitorCallback cb, |
566 | void *cb_cls); | 560 | void *cb_cls); |
567 | 561 | ||
568 | 562 | ||
569 | /** | 563 | /** |
@@ -574,7 +568,7 @@ GNUNET_TRANSPORT_monitor_plugins (const struct GNUNET_CONFIGURATION_Handle *cfg, | |||
574 | * @param pm handle of the request that is to be cancelled | 568 | * @param pm handle of the request that is to be cancelled |
575 | */ | 569 | */ |
576 | void | 570 | void |
577 | GNUNET_TRANSPORT_monitor_plugins_cancel ( | 571 | GNUNET_TRANSPORT_monitor_plugins_cancel( |
578 | struct GNUNET_TRANSPORT_PluginMonitor *pm); | 572 | struct GNUNET_TRANSPORT_PluginMonitor *pm); |
579 | 573 | ||
580 | 574 | ||
@@ -659,13 +653,13 @@ typedef void (*GNUNET_TRANSPORT_NotifyExcessBandwidth) ( | |||
659 | * @return NULL on error | 653 | * @return NULL on error |
660 | */ | 654 | */ |
661 | struct GNUNET_TRANSPORT_CoreHandle * | 655 | struct GNUNET_TRANSPORT_CoreHandle * |
662 | GNUNET_TRANSPORT_core_connect (const struct GNUNET_CONFIGURATION_Handle *cfg, | 656 | GNUNET_TRANSPORT_core_connect(const struct GNUNET_CONFIGURATION_Handle *cfg, |
663 | const struct GNUNET_PeerIdentity *self, | 657 | const struct GNUNET_PeerIdentity *self, |
664 | const struct GNUNET_MQ_MessageHandler *handlers, | 658 | const struct GNUNET_MQ_MessageHandler *handlers, |
665 | void *cls, | 659 | void *cls, |
666 | GNUNET_TRANSPORT_NotifyConnect nc, | 660 | GNUNET_TRANSPORT_NotifyConnect nc, |
667 | GNUNET_TRANSPORT_NotifyDisconnect nd, | 661 | GNUNET_TRANSPORT_NotifyDisconnect nd, |
668 | GNUNET_TRANSPORT_NotifyExcessBandwidth neb); | 662 | GNUNET_TRANSPORT_NotifyExcessBandwidth neb); |
669 | 663 | ||
670 | 664 | ||
671 | /** | 665 | /** |
@@ -674,7 +668,7 @@ GNUNET_TRANSPORT_core_connect (const struct GNUNET_CONFIGURATION_Handle *cfg, | |||
674 | * @param handle handle returned from connect | 668 | * @param handle handle returned from connect |
675 | */ | 669 | */ |
676 | void | 670 | void |
677 | GNUNET_TRANSPORT_core_disconnect (struct GNUNET_TRANSPORT_CoreHandle *handle); | 671 | GNUNET_TRANSPORT_core_disconnect(struct GNUNET_TRANSPORT_CoreHandle *handle); |
678 | 672 | ||
679 | 673 | ||
680 | /** | 674 | /** |
@@ -685,8 +679,8 @@ GNUNET_TRANSPORT_core_disconnect (struct GNUNET_TRANSPORT_CoreHandle *handle); | |||
685 | * @return NULL if disconnected, otherwise message queue for @a peer | 679 | * @return NULL if disconnected, otherwise message queue for @a peer |
686 | */ | 680 | */ |
687 | struct GNUNET_MQ_Handle * | 681 | struct GNUNET_MQ_Handle * |
688 | GNUNET_TRANSPORT_core_get_mq (struct GNUNET_TRANSPORT_CoreHandle *handle, | 682 | GNUNET_TRANSPORT_core_get_mq(struct GNUNET_TRANSPORT_CoreHandle *handle, |
689 | const struct GNUNET_PeerIdentity *peer); | 683 | const struct GNUNET_PeerIdentity *peer); |
690 | 684 | ||
691 | 685 | ||
692 | #if 0 /* keep Emacsens' auto-indent happy */ | 686 | #if 0 /* keep Emacsens' auto-indent happy */ |