diff options
author | Christian Grothoff <christian@grothoff.org> | 2011-11-04 14:00:32 +0000 |
---|---|---|
committer | Christian Grothoff <christian@grothoff.org> | 2011-11-04 14:00:32 +0000 |
commit | 83b19539f4d322b43683f5838b72e9ec2c8e6073 (patch) | |
tree | d0ab9329fcbefe360d9d14e2ace21a6b3396dfe9 /src/include | |
parent | 28a2eb43281a1f08a67954f07beb9af3a9bc9a35 (diff) | |
download | gnunet-83b19539f4d322b43683f5838b72e9ec2c8e6073.tar.gz gnunet-83b19539f4d322b43683f5838b72e9ec2c8e6073.zip |
curly wars / auto-indentation
Diffstat (limited to 'src/include')
-rw-r--r-- | src/include/gnunet_ats_service.h | 185 | ||||
-rw-r--r-- | src/include/gnunet_block_lib.h | 4 | ||||
-rw-r--r-- | src/include/gnunet_common.h | 8 | ||||
-rw-r--r-- | src/include/gnunet_core_service.h | 14 | ||||
-rw-r--r-- | src/include/gnunet_dht_service.h | 11 | ||||
-rw-r--r-- | src/include/gnunet_mesh_service.h | 8 | ||||
-rw-r--r-- | src/include/gnunet_plugin_lib.h | 14 | ||||
-rw-r--r-- | src/include/gnunet_server_lib.h | 3 | ||||
-rw-r--r-- | src/include/gnunet_strings_lib.h | 4 | ||||
-rw-r--r-- | src/include/gnunet_transport_service.h | 10 |
10 files changed, 108 insertions, 153 deletions
diff --git a/src/include/gnunet_ats_service.h b/src/include/gnunet_ats_service.h index ed5631a33..ac963ce1d 100644 --- a/src/include/gnunet_ats_service.h +++ b/src/include/gnunet_ats_service.h | |||
@@ -49,14 +49,14 @@ enum GNUNET_ATS_Property | |||
49 | 49 | ||
50 | /** | 50 | /** |
51 | * Actual traffic on this connection from the other peer to this peer. | 51 | * Actual traffic on this connection from the other peer to this peer. |
52 | * | 52 | * |
53 | * Unit: [bytes/second] | 53 | * Unit: [bytes/second] |
54 | */ | 54 | */ |
55 | GNUNET_ATS_UTILIZATION_UP, | 55 | GNUNET_ATS_UTILIZATION_UP, |
56 | 56 | ||
57 | /** | 57 | /** |
58 | * Actual traffic on this connection from this peer to the other peer. | 58 | * Actual traffic on this connection from this peer to the other peer. |
59 | * | 59 | * |
60 | * Unit: [bytes/second] | 60 | * Unit: [bytes/second] |
61 | */ | 61 | */ |
62 | GNUNET_ATS_UTILIZATION_DOWN, | 62 | GNUNET_ATS_UTILIZATION_DOWN, |
@@ -74,14 +74,14 @@ enum GNUNET_ATS_Property | |||
74 | * Dialup: 500 | 74 | * Dialup: 500 |
75 | */ | 75 | */ |
76 | GNUNET_ATS_QUALITY_NET_DELAY, | 76 | GNUNET_ATS_QUALITY_NET_DELAY, |
77 | 77 | ||
78 | /** | 78 | /** |
79 | * Distance on network layer (required for distance-vector routing). | 79 | * Distance on network layer (required for distance-vector routing). |
80 | * | 80 | * |
81 | * Unit: [DV-hops] | 81 | * Unit: [DV-hops] |
82 | */ | 82 | */ |
83 | GNUNET_ATS_QUALITY_NET_DISTANCE, | 83 | GNUNET_ATS_QUALITY_NET_DISTANCE, |
84 | 84 | ||
85 | /** | 85 | /** |
86 | * Network overhead on WAN (Wide-Area Network) | 86 | * Network overhead on WAN (Wide-Area Network) |
87 | * | 87 | * |
@@ -102,7 +102,7 @@ enum GNUNET_ATS_Property | |||
102 | * UDP/IPv6 over Ethernet: 1024 + 38 + 40 + 8 = 1110 [bytes/kb] | 102 | * UDP/IPv6 over Ethernet: 1024 + 38 + 40 + 8 = 1110 [bytes/kb] |
103 | */ | 103 | */ |
104 | GNUNET_ATS_COST_WAN, | 104 | GNUNET_ATS_COST_WAN, |
105 | 105 | ||
106 | /** | 106 | /** |
107 | * Network overhead on LAN (Local-Area Network) | 107 | * Network overhead on LAN (Local-Area Network) |
108 | * | 108 | * |
@@ -123,7 +123,7 @@ enum GNUNET_ATS_Property | |||
123 | * UDP/IPv6 over Ethernet: 1024 + 38 + 40 + 8 = 1110 [bytes/kb] | 123 | * UDP/IPv6 over Ethernet: 1024 + 38 + 40 + 8 = 1110 [bytes/kb] |
124 | */ | 124 | */ |
125 | GNUNET_ATS_COST_LAN, | 125 | GNUNET_ATS_COST_LAN, |
126 | 126 | ||
127 | /** | 127 | /** |
128 | * Network overhead on WLAN (Wireless Local Area Network) | 128 | * Network overhead on WLAN (Wireless Local Area Network) |
129 | * | 129 | * |
@@ -144,12 +144,8 @@ enum GNUNET_ATS_Property | |||
144 | * UDP/IPv6 over Ethernet: 1024 + 38 + 40 + 8 = 1110 [bytes/kb] | 144 | * UDP/IPv6 over Ethernet: 1024 + 38 + 40 + 8 = 1110 [bytes/kb] |
145 | */ | 145 | */ |
146 | GNUNET_ATS_COST_WLAN | 146 | GNUNET_ATS_COST_WLAN |
147 | 147 | /* Cost related values */ | |
148 | 148 | /* =================== */ | |
149 | |||
150 | /* Cost related values */ | ||
151 | /* =================== */ | ||
152 | |||
153 | /** | 149 | /** |
154 | * Volume based cost in financial units to transmit data | 150 | * Volume based cost in financial units to transmit data |
155 | * | 151 | * |
@@ -166,8 +162,7 @@ enum GNUNET_ATS_Property | |||
166 | * LAN: 0 [cent/MB] | 162 | * LAN: 0 [cent/MB] |
167 | * 2G : 10 [cent/MB] | 163 | * 2G : 10 [cent/MB] |
168 | */ | 164 | */ |
169 | // GNUNET_ATS_COST_FINANCIAL_PER_VOLUME = 1, | 165 | // GNUNET_ATS_COST_FINANCIAL_PER_VOLUME = 1, |
170 | |||
171 | /** | 166 | /** |
172 | * Time based cost in financial units to transmit data | 167 | * Time based cost in financial units to transmit data |
173 | * | 168 | * |
@@ -184,8 +179,7 @@ enum GNUNET_ATS_Property | |||
184 | * LAN : 0 [cent/h] | 179 | * LAN : 0 [cent/h] |
185 | * Dialup: 10 [cent/h] | 180 | * Dialup: 10 [cent/h] |
186 | */ | 181 | */ |
187 | // GNUNET_ATS_COST_FINANCIAL_PER_TIME = 2, | 182 | // GNUNET_ATS_COST_FINANCIAL_PER_TIME = 2, |
188 | |||
189 | /** | 183 | /** |
190 | * Computational costs | 184 | * Computational costs |
191 | * | 185 | * |
@@ -204,8 +198,7 @@ enum GNUNET_ATS_Property | |||
204 | * HTTPS with AES CBC-128: 5,279 | 198 | * HTTPS with AES CBC-128: 5,279 |
205 | * HTTPS with RC4-1024: 2,652 | 199 | * HTTPS with RC4-1024: 2,652 |
206 | */ | 200 | */ |
207 | // GNUNET_ATS_COST_COMPUTATIONAL = 3, | 201 | // GNUNET_ATS_COST_COMPUTATIONAL = 3, |
208 | |||
209 | /** | 202 | /** |
210 | * Energy consumption | 203 | * Energy consumption |
211 | * | 204 | * |
@@ -233,8 +226,7 @@ enum GNUNET_ATS_Property | |||
233 | * WLAN: 89 (600 mW @ 802.11g /w 54 MBit/s) | 226 | * WLAN: 89 (600 mW @ 802.11g /w 54 MBit/s) |
234 | * Bluetooth: 267 (100 mW @ BT2.0 EDR /w 3 MBit/s) | 227 | * Bluetooth: 267 (100 mW @ BT2.0 EDR /w 3 MBit/s) |
235 | */ | 228 | */ |
236 | // GNUNET_ATS_COST_ENERGY_CONSUMPTION = 4, | 229 | // GNUNET_ATS_COST_ENERGY_CONSUMPTION = 4, |
237 | |||
238 | /** | 230 | /** |
239 | * Connect cost | 231 | * Connect cost |
240 | * How many bytes are transmitted to initiate a new connection using | 232 | * How many bytes are transmitted to initiate a new connection using |
@@ -256,8 +248,7 @@ enum GNUNET_ATS_Property | |||
256 | * 2129 bytes Ethernet, 1975 bytes TCP/IP, 1755 bytes TCP, 1403 bytes HTTPS | 248 | * 2129 bytes Ethernet, 1975 bytes TCP/IP, 1755 bytes TCP, 1403 bytes HTTPS |
257 | * | 249 | * |
258 | * */ | 250 | * */ |
259 | // GNUNET_ATS_COST_CONNECT = 5, | 251 | // GNUNET_ATS_COST_CONNECT = 5, |
260 | |||
261 | /** | 252 | /** |
262 | * Bandwidth cost | 253 | * Bandwidth cost |
263 | * | 254 | * |
@@ -274,8 +265,7 @@ enum GNUNET_ATS_Property | |||
274 | * Dial-up: 8 (64 Kbit/s) | 265 | * Dial-up: 8 (64 Kbit/s) |
275 | * | 266 | * |
276 | */ | 267 | */ |
277 | // GNUNET_ATS_COST_BANDWITH_AVAILABLE = 6, | 268 | // GNUNET_ATS_COST_BANDWITH_AVAILABLE = 6, |
278 | |||
279 | /** | 269 | /** |
280 | * Network overhead | 270 | * Network overhead |
281 | * | 271 | * |
@@ -295,35 +285,28 @@ enum GNUNET_ATS_Property | |||
295 | * UDP/IPv4 over Ethernet: 1024 + 38 + 20 + 8 = 1090 [bytes/kb] | 285 | * UDP/IPv4 over Ethernet: 1024 + 38 + 20 + 8 = 1090 [bytes/kb] |
296 | * UDP/IPv6 over Ethernet: 1024 + 38 + 40 + 8 = 1110 [bytes/kb] | 286 | * UDP/IPv6 over Ethernet: 1024 + 38 + 40 + 8 = 1110 [bytes/kb] |
297 | */ | 287 | */ |
298 | // GNUNET_ATS_COST_NETWORK_OVERHEAD = 7, | 288 | // GNUNET_ATS_COST_NETWORK_OVERHEAD = 7, |
299 | 289 | /* Quality related values */ | |
300 | 290 | /* ====================== */ | |
301 | /* Quality related values */ | 291 | /* Physical layer quality properties */ |
302 | /* ====================== */ | ||
303 | |||
304 | /* Physical layer quality properties */ | ||
305 | |||
306 | /** | 292 | /** |
307 | * Signal strength on physical layer | 293 | * Signal strength on physical layer |
308 | * | 294 | * |
309 | * Unit: [dBm] | 295 | * Unit: [dBm] |
310 | */ | 296 | */ |
311 | // GNUNET_ATS_QUALITY_PHY_SIGNAL_STRENGTH = 1025, | 297 | // GNUNET_ATS_QUALITY_PHY_SIGNAL_STRENGTH = 1025, |
312 | |||
313 | /** | 298 | /** |
314 | * Collision rate on physical layer | 299 | * Collision rate on physical layer |
315 | * | 300 | * |
316 | * Unit: [B/s] | 301 | * Unit: [B/s] |
317 | */ | 302 | */ |
318 | // GNUNET_ATS_QUALITY_PHY_COLLISION_RATE = 1026, | 303 | // GNUNET_ATS_QUALITY_PHY_COLLISION_RATE = 1026, |
319 | |||
320 | /** | 304 | /** |
321 | * Error rate on physical layer | 305 | * Error rate on physical layer |
322 | * | 306 | * |
323 | * Unit: [B/s] | 307 | * Unit: [B/s] |
324 | */ | 308 | */ |
325 | // GNUNET_ATS_QUALITY_PHY_ERROR_RATE = 1027, | 309 | // GNUNET_ATS_QUALITY_PHY_ERROR_RATE = 1027, |
326 | |||
327 | /** | 310 | /** |
328 | * Jitter | 311 | * Jitter |
329 | * Time variations of the delay | 312 | * Time variations of the delay |
@@ -331,8 +314,7 @@ enum GNUNET_ATS_Property | |||
331 | * | 314 | * |
332 | * Unit: [ms] | 315 | * Unit: [ms] |
333 | */ | 316 | */ |
334 | // GNUNET_ATS_QUALITY_NET_JITTER = 1029, | 317 | // GNUNET_ATS_QUALITY_NET_JITTER = 1029, |
335 | |||
336 | /** | 318 | /** |
337 | * Error rate on network layer | 319 | * Error rate on network layer |
338 | * | 320 | * |
@@ -346,8 +328,7 @@ enum GNUNET_ATS_Property | |||
346 | * Note: This numbers are just assumptions as an example, not | 328 | * Note: This numbers are just assumptions as an example, not |
347 | * measured or somehow determined | 329 | * measured or somehow determined |
348 | */ | 330 | */ |
349 | // GNUNET_ATS_QUALITY_NET_ERRORRATE = 1030, | 331 | // GNUNET_ATS_QUALITY_NET_ERRORRATE = 1030, |
350 | |||
351 | /** | 332 | /** |
352 | * Drop rate on network layer | 333 | * Drop rate on network layer |
353 | * Bytes actively dismissed by a network component during transmission | 334 | * Bytes actively dismissed by a network component during transmission |
@@ -363,8 +344,7 @@ enum GNUNET_ATS_Property | |||
363 | * Note: This numbers are just assumptions as an example, not | 344 | * Note: This numbers are just assumptions as an example, not |
364 | * measured or somehow determined | 345 | * measured or somehow determined |
365 | */ | 346 | */ |
366 | // GNUNET_ATS_QUALITY_NET_DROPRATE = 1031, | 347 | // GNUNET_ATS_QUALITY_NET_DROPRATE = 1031, |
367 | |||
368 | /** | 348 | /** |
369 | * Loss rate on network layer | 349 | * Loss rate on network layer |
370 | * Bytes lost during transmission | 350 | * Bytes lost during transmission |
@@ -380,8 +360,7 @@ enum GNUNET_ATS_Property | |||
380 | * Note: This numbers are just assumptions as an example, not measured | 360 | * Note: This numbers are just assumptions as an example, not measured |
381 | * or somehow determined | 361 | * or somehow determined |
382 | */ | 362 | */ |
383 | // GNUNET_ATS_QUALITY_NET_LOSSRATE = 1032, | 363 | // GNUNET_ATS_QUALITY_NET_LOSSRATE = 1032, |
384 | |||
385 | /** | 364 | /** |
386 | * Throughput on network layer | 365 | * Throughput on network layer |
387 | * | 366 | * |
@@ -394,21 +373,17 @@ enum GNUNET_ATS_Property | |||
394 | * Dialup: 4 | 373 | * Dialup: 4 |
395 | * | 374 | * |
396 | */ | 375 | */ |
397 | // GNUNET_ATS_QUALITY_NET_THROUGHPUT = 1033, | 376 | // GNUNET_ATS_QUALITY_NET_THROUGHPUT = 1033, |
398 | 377 | /* Availability related values */ | |
399 | 378 | /* =========================== */ | |
400 | /* Availability related values */ | ||
401 | /* =========================== */ | ||
402 | |||
403 | /** | 379 | /** |
404 | * Is a peer reachable? | 380 | * Is a peer reachable? |
405 | */ | 381 | */ |
406 | // GNUNET_ATS_AVAILABILITY_REACHABLE = 2048, | 382 | // GNUNET_ATS_AVAILABILITY_REACHABLE = 2048, |
407 | |||
408 | /** | 383 | /** |
409 | * Is there a connection established to a peer using this transport | 384 | * Is there a connection established to a peer using this transport |
410 | */ | 385 | */ |
411 | // GNUNET_ATS_AVAILABILITY_CONNECTED = 2049 | 386 | // GNUNET_ATS_AVAILABILITY_CONNECTED = 2049 |
412 | }; | 387 | }; |
413 | 388 | ||
414 | 389 | ||
@@ -461,7 +436,7 @@ struct Session; | |||
461 | 436 | ||
462 | /** | 437 | /** |
463 | * Signature of a function called by ATS with the current bandwidth | 438 | * Signature of a function called by ATS with the current bandwidth |
464 | * and address preferences as determined by ATS. | 439 | * and address preferences as determined by ATS. |
465 | * | 440 | * |
466 | * @param cls closure | 441 | * @param cls closure |
467 | * @param peer identity of the new peer | 442 | * @param peer identity of the new peer |
@@ -488,10 +463,9 @@ typedef void (*GNUNET_ATS_AddressSuggestionCallback) (void *cls, | |||
488 | struct | 463 | struct |
489 | GNUNET_BANDWIDTH_Value32NBO | 464 | GNUNET_BANDWIDTH_Value32NBO |
490 | bandwidth_in, | 465 | bandwidth_in, |
491 | const struct | 466 | const struct |
492 | GNUNET_ATS_Information | 467 | GNUNET_ATS_Information * |
493 | * ats, | 468 | ats, uint32_t ats_count); |
494 | uint32_t ats_count); | ||
495 | 469 | ||
496 | 470 | ||
497 | /** | 471 | /** |
@@ -504,8 +478,8 @@ typedef void (*GNUNET_ATS_AddressSuggestionCallback) (void *cls, | |||
504 | */ | 478 | */ |
505 | struct GNUNET_ATS_SchedulingHandle * | 479 | struct GNUNET_ATS_SchedulingHandle * |
506 | GNUNET_ATS_scheduling_init (const struct GNUNET_CONFIGURATION_Handle *cfg, | 480 | GNUNET_ATS_scheduling_init (const struct GNUNET_CONFIGURATION_Handle *cfg, |
507 | GNUNET_ATS_AddressSuggestionCallback suggest_cb, | 481 | GNUNET_ATS_AddressSuggestionCallback suggest_cb, |
508 | void *suggest_cb_cls); | 482 | void *suggest_cb_cls); |
509 | 483 | ||
510 | 484 | ||
511 | /** | 485 | /** |
@@ -549,9 +523,8 @@ GNUNET_ATS_suggest_address (struct GNUNET_ATS_SchedulingHandle *sh, | |||
549 | void | 523 | void |
550 | GNUNET_ATS_address_update (struct GNUNET_ATS_SchedulingHandle *sh, | 524 | GNUNET_ATS_address_update (struct GNUNET_ATS_SchedulingHandle *sh, |
551 | const struct GNUNET_PeerIdentity *peer, | 525 | const struct GNUNET_PeerIdentity *peer, |
552 | const char *plugin_name, | 526 | const char *plugin_name, const void *plugin_addr, |
553 | const void *plugin_addr, size_t plugin_addr_len, | 527 | size_t plugin_addr_len, struct Session *session, |
554 | struct Session *session, | ||
555 | const struct GNUNET_ATS_Information *ats, | 528 | const struct GNUNET_ATS_Information *ats, |
556 | uint32_t ats_count); | 529 | uint32_t ats_count); |
557 | 530 | ||
@@ -570,12 +543,10 @@ GNUNET_ATS_address_update (struct GNUNET_ATS_SchedulingHandle *sh, | |||
570 | */ | 543 | */ |
571 | void | 544 | void |
572 | GNUNET_ATS_address_in_use (struct GNUNET_ATS_SchedulingHandle *sh, | 545 | GNUNET_ATS_address_in_use (struct GNUNET_ATS_SchedulingHandle *sh, |
573 | const struct GNUNET_PeerIdentity *peer, | 546 | const struct GNUNET_PeerIdentity *peer, |
574 | const char *plugin_name, | 547 | const char *plugin_name, const void *plugin_addr, |
575 | const void *plugin_addr, | 548 | size_t plugin_addr_len, struct Session *session, |
576 | size_t plugin_addr_len, | 549 | int in_use); |
577 | struct Session *session, | ||
578 | int in_use); | ||
579 | 550 | ||
580 | /** | 551 | /** |
581 | * A session got destroyed, stop including it as a valid address. | 552 | * A session got destroyed, stop including it as a valid address. |
@@ -590,10 +561,8 @@ GNUNET_ATS_address_in_use (struct GNUNET_ATS_SchedulingHandle *sh, | |||
590 | void | 561 | void |
591 | GNUNET_ATS_address_destroyed (struct GNUNET_ATS_SchedulingHandle *sh, | 562 | GNUNET_ATS_address_destroyed (struct GNUNET_ATS_SchedulingHandle *sh, |
592 | const struct GNUNET_PeerIdentity *peer, | 563 | const struct GNUNET_PeerIdentity *peer, |
593 | const char *plugin_name, | 564 | const char *plugin_name, const void *plugin_addr, |
594 | const void *plugin_addr, | 565 | size_t plugin_addr_len, struct Session *session); |
595 | size_t plugin_addr_len, | ||
596 | struct Session *session); | ||
597 | 566 | ||
598 | 567 | ||
599 | /* ******************************** Performance API ***************************** */ | 568 | /* ******************************** Performance API ***************************** */ |
@@ -618,22 +587,20 @@ struct GNUNET_ATS_PerformanceHandle; | |||
618 | * @param ats_count number of performance records in 'ats' | 587 | * @param ats_count number of performance records in 'ats' |
619 | */ | 588 | */ |
620 | typedef void (*GNUNET_ATS_PeerInformationCallback) (void *cls, | 589 | typedef void (*GNUNET_ATS_PeerInformationCallback) (void *cls, |
621 | const struct | 590 | const struct |
622 | GNUNET_PeerIdentity * | 591 | GNUNET_PeerIdentity * peer, |
623 | peer, | 592 | const char *plugin_name, |
624 | const char *plugin_name, | 593 | const void *plugin_addr, |
625 | const void *plugin_addr, | 594 | size_t plugin_addr_len, |
626 | size_t plugin_addr_len, | 595 | struct |
627 | struct | 596 | GNUNET_BANDWIDTH_Value32NBO |
628 | GNUNET_BANDWIDTH_Value32NBO | 597 | bandwidth_out, |
629 | bandwidth_out, | 598 | struct |
630 | struct | 599 | GNUNET_BANDWIDTH_Value32NBO |
631 | GNUNET_BANDWIDTH_Value32NBO | 600 | bandwidth_in, |
632 | bandwidth_in, | 601 | const struct |
633 | const struct | 602 | GNUNET_ATS_Information * |
634 | GNUNET_ATS_Information | 603 | ats, uint32_t ats_count); |
635 | * ats, | ||
636 | uint32_t ats_count); | ||
637 | 604 | ||
638 | 605 | ||
639 | /** | 606 | /** |
@@ -646,8 +613,8 @@ typedef void (*GNUNET_ATS_PeerInformationCallback) (void *cls, | |||
646 | */ | 613 | */ |
647 | struct GNUNET_ATS_PerformanceHandle * | 614 | struct GNUNET_ATS_PerformanceHandle * |
648 | GNUNET_ATS_performance_init (const struct GNUNET_CONFIGURATION_Handle *cfg, | 615 | GNUNET_ATS_performance_init (const struct GNUNET_CONFIGURATION_Handle *cfg, |
649 | GNUNET_ATS_PeerInformationCallback infocb, | 616 | GNUNET_ATS_PeerInformationCallback infocb, |
650 | void *infocb_cls); | 617 | void *infocb_cls); |
651 | 618 | ||
652 | 619 | ||
653 | /** | 620 | /** |
@@ -670,13 +637,10 @@ GNUNET_ATS_performance_done (struct GNUNET_ATS_PerformanceHandle *ph); | |||
670 | * long should the client wait until re-trying? | 637 | * long should the client wait until re-trying? |
671 | */ | 638 | */ |
672 | typedef void (*GNUNET_ATS_ReservationCallback) (void *cls, | 639 | typedef void (*GNUNET_ATS_ReservationCallback) (void *cls, |
673 | const struct | 640 | const struct GNUNET_PeerIdentity |
674 | GNUNET_PeerIdentity * | 641 | * peer, int32_t amount, |
675 | peer, | 642 | struct GNUNET_TIME_Relative |
676 | int32_t amount, | 643 | res_delay); |
677 | struct | ||
678 | GNUNET_TIME_Relative | ||
679 | res_delay); | ||
680 | 644 | ||
681 | 645 | ||
682 | 646 | ||
@@ -702,10 +666,10 @@ struct GNUNET_ATS_ReservationContext; | |||
702 | */ | 666 | */ |
703 | struct GNUNET_ATS_ReservationContext * | 667 | struct GNUNET_ATS_ReservationContext * |
704 | GNUNET_ATS_reserve_bandwidth (struct GNUNET_ATS_PerformanceHandle *ph, | 668 | GNUNET_ATS_reserve_bandwidth (struct GNUNET_ATS_PerformanceHandle *ph, |
705 | const struct GNUNET_PeerIdentity *peer, | 669 | const struct GNUNET_PeerIdentity *peer, |
706 | int32_t amount, | 670 | int32_t amount, |
707 | GNUNET_ATS_ReservationCallback rcb, | 671 | GNUNET_ATS_ReservationCallback rcb, |
708 | void *rcb_cls); | 672 | void *rcb_cls); |
709 | 673 | ||
710 | 674 | ||
711 | /** | 675 | /** |
@@ -714,8 +678,7 @@ GNUNET_ATS_reserve_bandwidth (struct GNUNET_ATS_PerformanceHandle *ph, | |||
714 | * @param rc context returned by the original GNUNET_ATS_reserve_bandwidth call | 678 | * @param rc context returned by the original GNUNET_ATS_reserve_bandwidth call |
715 | */ | 679 | */ |
716 | void | 680 | void |
717 | GNUNET_ATS_reserve_bandwidth_cancel (struct | 681 | GNUNET_ATS_reserve_bandwidth_cancel (struct GNUNET_ATS_ReservationContext *rc); |
718 | GNUNET_ATS_ReservationContext *rc); | ||
719 | 682 | ||
720 | 683 | ||
721 | 684 | ||
@@ -734,7 +697,7 @@ enum GNUNET_ATS_PreferenceKind | |||
734 | * Change the peer's bandwidth value (value per byte of bandwidth in | 697 | * Change the peer's bandwidth value (value per byte of bandwidth in |
735 | * the goal function) to the given amount. The argument is followed | 698 | * the goal function) to the given amount. The argument is followed |
736 | * by a double value giving the desired value (can be negative). | 699 | * by a double value giving the desired value (can be negative). |
737 | * Preference changes are forgotten if peers disconnect. | 700 | * Preference changes are forgotten if peers disconnect. |
738 | */ | 701 | */ |
739 | GNUNET_ATS_PREFERENCE_BANDWIDTH, | 702 | GNUNET_ATS_PREFERENCE_BANDWIDTH, |
740 | 703 | ||
@@ -746,22 +709,20 @@ enum GNUNET_ATS_PreferenceKind | |||
746 | * the latency preferences. | 709 | * the latency preferences. |
747 | */ | 710 | */ |
748 | GNUNET_ATS_PREFERENCE_LATENCY | 711 | GNUNET_ATS_PREFERENCE_LATENCY |
749 | |||
750 | }; | 712 | }; |
751 | 713 | ||
752 | 714 | ||
753 | /** | 715 | /** |
754 | * Change preferences for the given peer. Preference changes are forgotten if peers | 716 | * Change preferences for the given peer. Preference changes are forgotten if peers |
755 | * disconnect. | 717 | * disconnect. |
756 | * | 718 | * |
757 | * @param ph performance handle | 719 | * @param ph performance handle |
758 | * @param peer identifies the peer | 720 | * @param peer identifies the peer |
759 | * @param ... 0-terminated specification of the desired changes | 721 | * @param ... 0-terminated specification of the desired changes |
760 | */ | 722 | */ |
761 | void | 723 | void |
762 | GNUNET_ATS_change_preference (struct GNUNET_ATS_PerformanceHandle *ph, | 724 | GNUNET_ATS_change_preference (struct GNUNET_ATS_PerformanceHandle *ph, |
763 | const struct GNUNET_PeerIdentity *peer, | 725 | const struct GNUNET_PeerIdentity *peer, ...); |
764 | ...); | ||
765 | 726 | ||
766 | 727 | ||
767 | 728 | ||
diff --git a/src/include/gnunet_block_lib.h b/src/include/gnunet_block_lib.h index 8e7a59c8b..5e6eca76c 100644 --- a/src/include/gnunet_block_lib.h +++ b/src/include/gnunet_block_lib.h | |||
@@ -238,8 +238,8 @@ GNUNET_BLOCK_get_key (struct GNUNET_BLOCK_Context *ctx, | |||
238 | */ | 238 | */ |
239 | struct GNUNET_CONTAINER_BloomFilter * | 239 | struct GNUNET_CONTAINER_BloomFilter * |
240 | GNUNET_BLOCK_construct_bloomfilter (int32_t bf_mutator, | 240 | GNUNET_BLOCK_construct_bloomfilter (int32_t bf_mutator, |
241 | const GNUNET_HashCode *seen_results, | 241 | const GNUNET_HashCode * seen_results, |
242 | unsigned int seen_results_count); | 242 | unsigned int seen_results_count); |
243 | 243 | ||
244 | 244 | ||
245 | #if 0 /* keep Emacsens' auto-indent happy */ | 245 | #if 0 /* keep Emacsens' auto-indent happy */ |
diff --git a/src/include/gnunet_common.h b/src/include/gnunet_common.h index a46badc74..08c1f96c9 100644 --- a/src/include/gnunet_common.h +++ b/src/include/gnunet_common.h | |||
@@ -167,9 +167,11 @@ typedef void (*GNUNET_Logger) (void *cls, enum GNUNET_ErrorType kind, | |||
167 | * Number of log calls to ignore. | 167 | * Number of log calls to ignore. |
168 | */ | 168 | */ |
169 | extern unsigned int skip_log; | 169 | extern unsigned int skip_log; |
170 | |||
170 | #if !defined(GNUNET_CULL_LOGGING) | 171 | #if !defined(GNUNET_CULL_LOGGING) |
171 | int | 172 | int |
172 | GNUNET_get_log_call_status (int caller_level, const char *comp, const char *file, const char *function, int line); | 173 | GNUNET_get_log_call_status (int caller_level, const char *comp, |
174 | const char *file, const char *function, int line); | ||
173 | #endif | 175 | #endif |
174 | /** | 176 | /** |
175 | * Main log function. | 177 | * Main log function. |
@@ -214,7 +216,7 @@ GNUNET_log_nocheck (enum GNUNET_ErrorType kind, const char *message, ...); | |||
214 | */ | 216 | */ |
215 | void | 217 | void |
216 | GNUNET_log_from_nocheck (enum GNUNET_ErrorType kind, const char *comp, | 218 | GNUNET_log_from_nocheck (enum GNUNET_ErrorType kind, const char *comp, |
217 | const char *message, ...); | 219 | const char *message, ...); |
218 | 220 | ||
219 | #if !defined(GNUNET_CULL_LOGGING) | 221 | #if !defined(GNUNET_CULL_LOGGING) |
220 | #define GNUNET_log_from(kind,comp,...) do { int log_line = __LINE__;\ | 222 | #define GNUNET_log_from(kind,comp,...) do { int log_line = __LINE__;\ |
diff --git a/src/include/gnunet_core_service.h b/src/include/gnunet_core_service.h index 24c9aa598..1f6c0f329 100644 --- a/src/include/gnunet_core_service.h +++ b/src/include/gnunet_core_service.h | |||
@@ -63,9 +63,8 @@ typedef void (*GNUNET_CORE_ConnectEventHandler) (void *cls, | |||
63 | const struct | 63 | const struct |
64 | GNUNET_PeerIdentity * peer, | 64 | GNUNET_PeerIdentity * peer, |
65 | const struct | 65 | const struct |
66 | GNUNET_ATS_Information | 66 | GNUNET_ATS_Information * atsi, |
67 | * atsi, | 67 | unsigned int atsi_count); |
68 | unsigned int atsi_count); | ||
69 | 68 | ||
70 | 69 | ||
71 | /** | 70 | /** |
@@ -97,10 +96,8 @@ typedef int (*GNUNET_CORE_MessageCallback) (void *cls, | |||
97 | other, | 96 | other, |
98 | const struct GNUNET_MessageHeader * | 97 | const struct GNUNET_MessageHeader * |
99 | message, | 98 | message, |
100 | const struct | 99 | const struct GNUNET_ATS_Information |
101 | GNUNET_ATS_Information * | 100 | * atsi, unsigned int atsi_count); |
102 | atsi, | ||
103 | unsigned int atsi_count); | ||
104 | 101 | ||
105 | 102 | ||
106 | /** | 103 | /** |
@@ -142,7 +139,8 @@ struct GNUNET_CORE_MessageHandler | |||
142 | */ | 139 | */ |
143 | typedef void (*GNUNET_CORE_StartupCallback) (void *cls, | 140 | typedef void (*GNUNET_CORE_StartupCallback) (void *cls, |
144 | struct GNUNET_CORE_Handle * server, | 141 | struct GNUNET_CORE_Handle * server, |
145 | const struct GNUNET_PeerIdentity *my_identity); | 142 | const struct GNUNET_PeerIdentity * |
143 | my_identity); | ||
146 | 144 | ||
147 | 145 | ||
148 | /** | 146 | /** |
diff --git a/src/include/gnunet_dht_service.h b/src/include/gnunet_dht_service.h index fcbc8df47..f047bd8f8 100644 --- a/src/include/gnunet_dht_service.h +++ b/src/include/gnunet_dht_service.h | |||
@@ -165,10 +165,10 @@ GNUNET_DHT_put (struct GNUNET_DHT_Handle *handle, const GNUNET_HashCode * key, | |||
165 | typedef void (*GNUNET_DHT_GetIterator) (void *cls, | 165 | typedef void (*GNUNET_DHT_GetIterator) (void *cls, |
166 | struct GNUNET_TIME_Absolute exp, | 166 | struct GNUNET_TIME_Absolute exp, |
167 | const GNUNET_HashCode * key, | 167 | const GNUNET_HashCode * key, |
168 | const struct GNUNET_PeerIdentity *get_path, | 168 | const struct GNUNET_PeerIdentity * |
169 | unsigned int get_path_length, | 169 | get_path, unsigned int get_path_length, |
170 | const struct GNUNET_PeerIdentity *put_path, | 170 | const struct GNUNET_PeerIdentity * |
171 | unsigned int put_path_length, | 171 | put_path, unsigned int put_path_length, |
172 | enum GNUNET_BLOCK_Type type, | 172 | enum GNUNET_BLOCK_Type type, |
173 | size_t size, const void *data); | 173 | size_t size, const void *data); |
174 | 174 | ||
@@ -197,8 +197,7 @@ GNUNET_DHT_get_start (struct GNUNET_DHT_Handle *handle, | |||
197 | struct GNUNET_TIME_Relative timeout, | 197 | struct GNUNET_TIME_Relative timeout, |
198 | enum GNUNET_BLOCK_Type type, const GNUNET_HashCode * key, | 198 | enum GNUNET_BLOCK_Type type, const GNUNET_HashCode * key, |
199 | uint32_t desired_replication_level, | 199 | uint32_t desired_replication_level, |
200 | enum GNUNET_DHT_RouteOption options, | 200 | enum GNUNET_DHT_RouteOption options, const void *xquery, |
201 | const void *xquery, | ||
202 | size_t xquery_size, GNUNET_DHT_GetIterator iter, | 201 | size_t xquery_size, GNUNET_DHT_GetIterator iter, |
203 | void *iter_cls); | 202 | void *iter_cls); |
204 | 203 | ||
diff --git a/src/include/gnunet_mesh_service.h b/src/include/gnunet_mesh_service.h index 0497cee2f..b9e95b46d 100644 --- a/src/include/gnunet_mesh_service.h +++ b/src/include/gnunet_mesh_service.h | |||
@@ -74,9 +74,8 @@ typedef int (*GNUNET_MESH_MessageCallback) (void *cls, | |||
74 | sender, | 74 | sender, |
75 | const struct GNUNET_MessageHeader * | 75 | const struct GNUNET_MessageHeader * |
76 | message, | 76 | message, |
77 | const struct | 77 | const struct GNUNET_ATS_Information |
78 | GNUNET_ATS_Information * | 78 | * atsi); |
79 | atsi); | ||
80 | 79 | ||
81 | 80 | ||
82 | /** | 81 | /** |
@@ -208,8 +207,7 @@ typedef void (*GNUNET_MESH_PeerConnectHandler) (void *cls, | |||
208 | const struct GNUNET_PeerIdentity | 207 | const struct GNUNET_PeerIdentity |
209 | * peer, | 208 | * peer, |
210 | const struct | 209 | const struct |
211 | GNUNET_ATS_Information | 210 | GNUNET_ATS_Information * atsi); |
212 | * atsi); | ||
213 | 211 | ||
214 | 212 | ||
215 | 213 | ||
diff --git a/src/include/gnunet_plugin_lib.h b/src/include/gnunet_plugin_lib.h index ff795d975..387ca381c 100644 --- a/src/include/gnunet_plugin_lib.h +++ b/src/include/gnunet_plugin_lib.h | |||
@@ -89,9 +89,9 @@ GNUNET_PLUGIN_load (const char *library_name, void *arg); | |||
89 | * of the library (same as what 'GNUNET_PLUGIN_load' would | 89 | * of the library (same as what 'GNUNET_PLUGIN_load' would |
90 | * have returned for the given library name) | 90 | * have returned for the given library name) |
91 | */ | 91 | */ |
92 | typedef void (*GNUNET_PLUGIN_LoaderCallback)(void *cls, | 92 | typedef void (*GNUNET_PLUGIN_LoaderCallback) (void *cls, |
93 | const char *library_name, | 93 | const char *library_name, |
94 | void *lib_ret); | 94 | void *lib_ret); |
95 | 95 | ||
96 | 96 | ||
97 | /** | 97 | /** |
@@ -106,11 +106,9 @@ typedef void (*GNUNET_PLUGIN_LoaderCallback)(void *cls, | |||
106 | * @param cb function to call for each plugin found | 106 | * @param cb function to call for each plugin found |
107 | * @param cb_cls closure for 'cb' | 107 | * @param cb_cls closure for 'cb' |
108 | */ | 108 | */ |
109 | void | 109 | void |
110 | GNUNET_PLUGIN_load_all (const char *basename, | 110 | GNUNET_PLUGIN_load_all (const char *basename, void *arg, |
111 | void *arg, | 111 | GNUNET_PLUGIN_LoaderCallback cb, void *cb_cls); |
112 | GNUNET_PLUGIN_LoaderCallback cb, | ||
113 | void *cb_cls); | ||
114 | 112 | ||
115 | 113 | ||
116 | /** | 114 | /** |
diff --git a/src/include/gnunet_server_lib.h b/src/include/gnunet_server_lib.h index 5289a6270..c39349c92 100644 --- a/src/include/gnunet_server_lib.h +++ b/src/include/gnunet_server_lib.h | |||
@@ -489,8 +489,7 @@ GNUNET_SERVER_transmit_context_run (struct GNUNET_SERVER_TransmitContext *tc, | |||
489 | */ | 489 | */ |
490 | void | 490 | void |
491 | GNUNET_SERVER_transmit_context_destroy (struct GNUNET_SERVER_TransmitContext | 491 | GNUNET_SERVER_transmit_context_destroy (struct GNUNET_SERVER_TransmitContext |
492 | *tc, | 492 | *tc, int success); |
493 | int success); | ||
494 | 493 | ||
495 | 494 | ||
496 | /** | 495 | /** |
diff --git a/src/include/gnunet_strings_lib.h b/src/include/gnunet_strings_lib.h index 5a4996c3b..4efecc863 100644 --- a/src/include/gnunet_strings_lib.h +++ b/src/include/gnunet_strings_lib.h | |||
@@ -59,7 +59,7 @@ extern "C" | |||
59 | */ | 59 | */ |
60 | int | 60 | int |
61 | GNUNET_STRINGS_fancy_size_to_bytes (const char *fancy_size, | 61 | GNUNET_STRINGS_fancy_size_to_bytes (const char *fancy_size, |
62 | unsigned long long *size); | 62 | unsigned long long *size); |
63 | 63 | ||
64 | 64 | ||
65 | /** | 65 | /** |
@@ -72,7 +72,7 @@ GNUNET_STRINGS_fancy_size_to_bytes (const char *fancy_size, | |||
72 | */ | 72 | */ |
73 | int | 73 | int |
74 | GNUNET_STRINGS_fancy_time_to_relative (const char *fancy_size, | 74 | GNUNET_STRINGS_fancy_time_to_relative (const char *fancy_size, |
75 | struct GNUNET_TIME_Relative *rtime); | 75 | struct GNUNET_TIME_Relative *rtime); |
76 | 76 | ||
77 | 77 | ||
78 | /** | 78 | /** |
diff --git a/src/include/gnunet_transport_service.h b/src/include/gnunet_transport_service.h index 2d6e515fa..de764e7a6 100644 --- a/src/include/gnunet_transport_service.h +++ b/src/include/gnunet_transport_service.h | |||
@@ -51,7 +51,7 @@ extern "C" | |||
51 | * @param peer (claimed) identity of the other peer | 51 | * @param peer (claimed) identity of the other peer |
52 | * @param message the message | 52 | * @param message the message |
53 | * @param ats performance data | 53 | * @param ats performance data |
54 | * @param ats_count number of entries in ats | 54 | * @param ats_count number of entries in ats |
55 | */ | 55 | */ |
56 | typedef void (*GNUNET_TRANSPORT_ReceiveCallback) (void *cls, | 56 | typedef void (*GNUNET_TRANSPORT_ReceiveCallback) (void *cls, |
57 | const struct | 57 | const struct |
@@ -60,8 +60,8 @@ typedef void (*GNUNET_TRANSPORT_ReceiveCallback) (void *cls, | |||
60 | GNUNET_MessageHeader * | 60 | GNUNET_MessageHeader * |
61 | message, | 61 | message, |
62 | const struct | 62 | const struct |
63 | GNUNET_ATS_Information | 63 | GNUNET_ATS_Information * ats, |
64 | * ats, uint32_t ats_count); | 64 | uint32_t ats_count); |
65 | 65 | ||
66 | 66 | ||
67 | /** | 67 | /** |
@@ -83,8 +83,8 @@ typedef void (*GNUNET_TRANSPORT_NotifyConnect) (void *cls, | |||
83 | const struct GNUNET_PeerIdentity | 83 | const struct GNUNET_PeerIdentity |
84 | * peer, | 84 | * peer, |
85 | const struct | 85 | const struct |
86 | GNUNET_ATS_Information | 86 | GNUNET_ATS_Information * ats, |
87 | * ats, uint32_t ats_count); | 87 | uint32_t ats_count); |
88 | 88 | ||
89 | /** | 89 | /** |
90 | * Function called to notify transport users that another | 90 | * Function called to notify transport users that another |