diff options
author | Matthias Wachs <wachs@net.in.tum.de> | 2013-03-21 14:08:37 +0000 |
---|---|---|
committer | Matthias Wachs <wachs@net.in.tum.de> | 2013-03-21 14:08:37 +0000 |
commit | 569a28bc648b2d073361fea5dcea2fb3daf5bd57 (patch) | |
tree | fcd7501aab6293d31bc4e82b0f59f24834325ee1 | |
parent | 1c01ca33a8a4120bd47ce22d1856cb2f81355628 (diff) | |
download | gnunet-569a28bc648b2d073361fea5dcea2fb3daf5bd57.tar.gz gnunet-569a28bc648b2d073361fea5dcea2fb3daf5bd57.zip |
api fix
20 files changed, 37 insertions, 102 deletions
diff --git a/src/include/gnunet_transport_service.h b/src/include/gnunet_transport_service.h index 25f73e33e..ec777e4ee 100644 --- a/src/include/gnunet_transport_service.h +++ b/src/include/gnunet_transport_service.h | |||
@@ -78,10 +78,7 @@ struct GNUNET_TRANSPORT_Handle; | |||
78 | */ | 78 | */ |
79 | typedef void (*GNUNET_TRANSPORT_NotifyConnect) (void *cls, | 79 | typedef void (*GNUNET_TRANSPORT_NotifyConnect) (void *cls, |
80 | const struct GNUNET_PeerIdentity | 80 | const struct GNUNET_PeerIdentity |
81 | * peer, | 81 | * peer); |
82 | const struct | ||
83 | GNUNET_ATS_Information * ats, | ||
84 | uint32_t ats_count); | ||
85 | 82 | ||
86 | /** | 83 | /** |
87 | * Function called to notify transport users that another | 84 | * Function called to notify transport users that another |
diff --git a/src/transport/gnunet-transport.c b/src/transport/gnunet-transport.c index d606f05b9..929963127 100644 --- a/src/transport/gnunet-transport.c +++ b/src/transport/gnunet-transport.c | |||
@@ -519,8 +519,7 @@ transmit_data (void *cls, size_t size, void *buf) | |||
519 | * @param ats_count number of entries in ats (excluding 0-termination) | 519 | * @param ats_count number of entries in ats (excluding 0-termination) |
520 | */ | 520 | */ |
521 | static void | 521 | static void |
522 | notify_connect (void *cls, const struct GNUNET_PeerIdentity *peer, | 522 | notify_connect (void *cls, const struct GNUNET_PeerIdentity *peer) |
523 | const struct GNUNET_ATS_Information *ats, uint32_t ats_count) | ||
524 | { | 523 | { |
525 | if (0 != memcmp (&pid, peer, sizeof (struct GNUNET_PeerIdentity))) | 524 | if (0 != memcmp (&pid, peer, sizeof (struct GNUNET_PeerIdentity))) |
526 | return; | 525 | return; |
@@ -598,12 +597,9 @@ notify_disconnect (void *cls, const struct GNUNET_PeerIdentity *peer) | |||
598 | * | 597 | * |
599 | * @param cls closure | 598 | * @param cls closure |
600 | * @param peer the peer that connected | 599 | * @param peer the peer that connected |
601 | * @param ats performance data | ||
602 | * @param ats_count number of entries in ats (excluding 0-termination) | ||
603 | */ | 600 | */ |
604 | static void | 601 | static void |
605 | monitor_notify_connect (void *cls, const struct GNUNET_PeerIdentity *peer, | 602 | monitor_notify_connect (void *cls, const struct GNUNET_PeerIdentity *peer) |
606 | const struct GNUNET_ATS_Information *ats, uint32_t ats_count) | ||
607 | { | 603 | { |
608 | monitor_connect_counter ++; | 604 | monitor_connect_counter ++; |
609 | struct GNUNET_TIME_Absolute now = GNUNET_TIME_absolute_get(); | 605 | struct GNUNET_TIME_Absolute now = GNUNET_TIME_absolute_get(); |
diff --git a/src/transport/test_quota_compliance.c b/src/transport/test_quota_compliance.c index 7f0247e50..37960e204 100644 --- a/src/transport/test_quota_compliance.c +++ b/src/transport/test_quota_compliance.c | |||
@@ -213,8 +213,7 @@ get_size (unsigned int iter) | |||
213 | 213 | ||
214 | static void | 214 | static void |
215 | notify_receive (void *cls, const struct GNUNET_PeerIdentity *peer, | 215 | notify_receive (void *cls, const struct GNUNET_PeerIdentity *peer, |
216 | const struct GNUNET_MessageHeader *message, | 216 | const struct GNUNET_MessageHeader *message) |
217 | const struct GNUNET_ATS_Information *ats, uint32_t ats_count) | ||
218 | { | 217 | { |
219 | static int n; | 218 | static int n; |
220 | unsigned int s; | 219 | unsigned int s; |
@@ -358,8 +357,7 @@ notify_ready (void *cls, size_t size, void *buf) | |||
358 | 357 | ||
359 | 358 | ||
360 | static void | 359 | static void |
361 | notify_connect (void *cls, const struct GNUNET_PeerIdentity *peer, | 360 | notify_connect (void *cls, const struct GNUNET_PeerIdentity *peer) |
362 | const struct GNUNET_ATS_Information *ats, uint32_t ats_count) | ||
363 | { | 361 | { |
364 | 362 | ||
365 | struct PeerContext *p = cls; | 363 | struct PeerContext *p = cls; |
diff --git a/src/transport/test_transport_api.c b/src/transport/test_transport_api.c index 1316efe25..774bdd540 100644 --- a/src/transport/test_transport_api.c +++ b/src/transport/test_transport_api.c | |||
@@ -151,8 +151,7 @@ end_badly (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc) | |||
151 | 151 | ||
152 | static void | 152 | static void |
153 | notify_receive (void *cls, const struct GNUNET_PeerIdentity *peer, | 153 | notify_receive (void *cls, const struct GNUNET_PeerIdentity *peer, |
154 | const struct GNUNET_MessageHeader *message, | 154 | const struct GNUNET_MessageHeader *message) |
155 | const struct GNUNET_ATS_Information *ats, uint32_t ats_count) | ||
156 | { | 155 | { |
157 | struct PeerContext *p = cls; | 156 | struct PeerContext *p = cls; |
158 | struct PeerContext *t = NULL; | 157 | struct PeerContext *t = NULL; |
@@ -246,8 +245,7 @@ sendtask (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc) | |||
246 | 245 | ||
247 | 246 | ||
248 | static void | 247 | static void |
249 | notify_connect (void *cls, const struct GNUNET_PeerIdentity *peer, | 248 | notify_connect (void *cls, const struct GNUNET_PeerIdentity *peer) |
250 | const struct GNUNET_ATS_Information *ats, uint32_t ats_count) | ||
251 | { | 249 | { |
252 | static int c; | 250 | static int c; |
253 | 251 | ||
diff --git a/src/transport/test_transport_api_bidirectional_connect.c b/src/transport/test_transport_api_bidirectional_connect.c index 39232160f..6745b9abb 100644 --- a/src/transport/test_transport_api_bidirectional_connect.c +++ b/src/transport/test_transport_api_bidirectional_connect.c | |||
@@ -126,8 +126,7 @@ end_badly (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc) | |||
126 | 126 | ||
127 | static void | 127 | static void |
128 | notify_receive (void *cls, const struct GNUNET_PeerIdentity *peer, | 128 | notify_receive (void *cls, const struct GNUNET_PeerIdentity *peer, |
129 | const struct GNUNET_MessageHeader *message, | 129 | const struct GNUNET_MessageHeader *message) |
130 | const struct GNUNET_ATS_Information *ats, uint32_t ats_count) | ||
131 | { | 130 | { |
132 | struct PeerContext *p = cls; | 131 | struct PeerContext *p = cls; |
133 | struct PeerContext *t = NULL; | 132 | struct PeerContext *t = NULL; |
@@ -219,8 +218,7 @@ sendtask (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc) | |||
219 | 218 | ||
220 | 219 | ||
221 | static void | 220 | static void |
222 | notify_connect (void *cls, const struct GNUNET_PeerIdentity *peer, | 221 | notify_connect (void *cls, const struct GNUNET_PeerIdentity *peer) |
223 | const struct GNUNET_ATS_Information *ats, uint32_t ats_count) | ||
224 | { | 222 | { |
225 | static int c; | 223 | static int c; |
226 | 224 | ||
diff --git a/src/transport/test_transport_api_blacklisting.c b/src/transport/test_transport_api_blacklisting.c index 55adb5b10..7186d1b3f 100644 --- a/src/transport/test_transport_api_blacklisting.c +++ b/src/transport/test_transport_api_blacklisting.c | |||
@@ -179,8 +179,7 @@ end_badly (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc) | |||
179 | 179 | ||
180 | static void | 180 | static void |
181 | notify_receive (void *cls, const struct GNUNET_PeerIdentity *peer, | 181 | notify_receive (void *cls, const struct GNUNET_PeerIdentity *peer, |
182 | const struct GNUNET_MessageHeader *message, | 182 | const struct GNUNET_MessageHeader *message) |
183 | const struct GNUNET_ATS_Information *ats, uint32_t ats_count) | ||
184 | { | 183 | { |
185 | struct PeerContext *p = cls; | 184 | struct PeerContext *p = cls; |
186 | struct PeerContext *t = NULL; | 185 | struct PeerContext *t = NULL; |
@@ -275,8 +274,7 @@ sendtask (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc) | |||
275 | } | 274 | } |
276 | 275 | ||
277 | static void | 276 | static void |
278 | notify_connect (void *cls, const struct GNUNET_PeerIdentity *peer, | 277 | notify_connect (void *cls, const struct GNUNET_PeerIdentity *peer) |
279 | const struct GNUNET_ATS_Information *ats, uint32_t ats_count) | ||
280 | { | 278 | { |
281 | static int c; | 279 | static int c; |
282 | 280 | ||
diff --git a/src/transport/test_transport_api_disconnect.c b/src/transport/test_transport_api_disconnect.c index 7a26c7eae..30f952a8a 100644 --- a/src/transport/test_transport_api_disconnect.c +++ b/src/transport/test_transport_api_disconnect.c | |||
@@ -178,8 +178,7 @@ stop_peer (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc) | |||
178 | 178 | ||
179 | static void | 179 | static void |
180 | notify_receive (void *cls, const struct GNUNET_PeerIdentity *peer, | 180 | notify_receive (void *cls, const struct GNUNET_PeerIdentity *peer, |
181 | const struct GNUNET_MessageHeader *message, | 181 | const struct GNUNET_MessageHeader *message) |
182 | const struct GNUNET_ATS_Information *ats, uint32_t ats_count) | ||
183 | { | 182 | { |
184 | struct PeerContext *p = cls; | 183 | struct PeerContext *p = cls; |
185 | struct PeerContext *t = NULL; | 184 | struct PeerContext *t = NULL; |
@@ -266,8 +265,7 @@ sendtask (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc) | |||
266 | 265 | ||
267 | 266 | ||
268 | static void | 267 | static void |
269 | notify_connect (void *cls, const struct GNUNET_PeerIdentity *peer, | 268 | notify_connect (void *cls, const struct GNUNET_PeerIdentity *peer) |
270 | const struct GNUNET_ATS_Information *ats, uint32_t ats_count) | ||
271 | { | 269 | { |
272 | static int c; | 270 | static int c; |
273 | 271 | ||
diff --git a/src/transport/test_transport_api_limited_sockets.c b/src/transport/test_transport_api_limited_sockets.c index 69a510005..b7a230283 100644 --- a/src/transport/test_transport_api_limited_sockets.c +++ b/src/transport/test_transport_api_limited_sockets.c | |||
@@ -132,8 +132,7 @@ end_badly (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc) | |||
132 | 132 | ||
133 | static void | 133 | static void |
134 | notify_receive (void *cls, const struct GNUNET_PeerIdentity *peer, | 134 | notify_receive (void *cls, const struct GNUNET_PeerIdentity *peer, |
135 | const struct GNUNET_MessageHeader *message, | 135 | const struct GNUNET_MessageHeader *message) |
136 | const struct GNUNET_ATS_Information *ats, uint32_t ats_count) | ||
137 | { | 136 | { |
138 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | 137 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
139 | "Received message of type %d from peer %s!\n", | 138 | "Received message of type %d from peer %s!\n", |
@@ -178,8 +177,7 @@ notify_ready (void *cls, size_t size, void *buf) | |||
178 | 177 | ||
179 | 178 | ||
180 | static void | 179 | static void |
181 | notify_connect (void *cls, const struct GNUNET_PeerIdentity *peer, | 180 | notify_connect (void *cls, const struct GNUNET_PeerIdentity *peer) |
182 | const struct GNUNET_ATS_Information *ats, uint32_t ats_count) | ||
183 | { | 181 | { |
184 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Peer `%4s' connected to us (%p)!\n", | 182 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Peer `%4s' connected to us (%p)!\n", |
185 | GNUNET_i2s (peer), cls); | 183 | GNUNET_i2s (peer), cls); |
diff --git a/src/transport/test_transport_api_manipulation_recv_tcp.c b/src/transport/test_transport_api_manipulation_recv_tcp.c index efd4a481f..83d1431dc 100644 --- a/src/transport/test_transport_api_manipulation_recv_tcp.c +++ b/src/transport/test_transport_api_manipulation_recv_tcp.c | |||
@@ -162,12 +162,10 @@ sendtask (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc); | |||
162 | 162 | ||
163 | static void | 163 | static void |
164 | notify_receive (void *cls, const struct GNUNET_PeerIdentity *peer, | 164 | notify_receive (void *cls, const struct GNUNET_PeerIdentity *peer, |
165 | const struct GNUNET_MessageHeader *message, | 165 | const struct GNUNET_MessageHeader *message) |
166 | const struct GNUNET_ATS_Information *ats, uint32_t ats_count) | ||
167 | { | 166 | { |
168 | struct PeerContext *p = cls; | 167 | struct PeerContext *p = cls; |
169 | struct PeerContext *t = NULL; | 168 | struct PeerContext *t = NULL; |
170 | int c; | ||
171 | 169 | ||
172 | if (0 == memcmp (peer, &p1->id, sizeof (struct GNUNET_PeerIdentity))) | 170 | if (0 == memcmp (peer, &p1->id, sizeof (struct GNUNET_PeerIdentity))) |
173 | t = p1; | 171 | t = p1; |
@@ -231,19 +229,6 @@ notify_receive (void *cls, const struct GNUNET_PeerIdentity *peer, | |||
231 | "Delayed message was not delayed correctly: took only %llu\n", | 229 | "Delayed message was not delayed correctly: took only %llu\n", |
232 | (long long unsigned int) dur_delayed.rel_value); | 230 | (long long unsigned int) dur_delayed.rel_value); |
233 | } | 231 | } |
234 | for (c = 0; c < ats_count; c++) | ||
235 | { | ||
236 | if (ntohl (ats[c].type) == GNUNET_ATS_QUALITY_NET_DISTANCE) | ||
237 | { | ||
238 | if (ntohl (ats[c].value) == 10) | ||
239 | ok += 0; | ||
240 | else | ||
241 | { | ||
242 | GNUNET_break (0); | ||
243 | ok += 1; | ||
244 | } | ||
245 | } | ||
246 | } | ||
247 | /* shutdown */ | 232 | /* shutdown */ |
248 | end (); | 233 | end (); |
249 | } | 234 | } |
@@ -323,8 +308,7 @@ sendtask (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc) | |||
323 | 308 | ||
324 | 309 | ||
325 | static void | 310 | static void |
326 | notify_connect (void *cls, const struct GNUNET_PeerIdentity *peer, | 311 | notify_connect (void *cls, const struct GNUNET_PeerIdentity *peer) |
327 | const struct GNUNET_ATS_Information *ats, uint32_t ats_count) | ||
328 | { | 312 | { |
329 | static int c; | 313 | static int c; |
330 | 314 | ||
diff --git a/src/transport/test_transport_api_manipulation_send_tcp.c b/src/transport/test_transport_api_manipulation_send_tcp.c index 3ec7f7bf3..5361e0aba 100644 --- a/src/transport/test_transport_api_manipulation_send_tcp.c +++ b/src/transport/test_transport_api_manipulation_send_tcp.c | |||
@@ -162,12 +162,10 @@ sendtask (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc); | |||
162 | 162 | ||
163 | static void | 163 | static void |
164 | notify_receive (void *cls, const struct GNUNET_PeerIdentity *peer, | 164 | notify_receive (void *cls, const struct GNUNET_PeerIdentity *peer, |
165 | const struct GNUNET_MessageHeader *message, | 165 | const struct GNUNET_MessageHeader *message) |
166 | const struct GNUNET_ATS_Information *ats, uint32_t ats_count) | ||
167 | { | 166 | { |
168 | struct PeerContext *p = cls; | 167 | struct PeerContext *p = cls; |
169 | struct PeerContext *t = NULL; | 168 | struct PeerContext *t = NULL; |
170 | int c; | ||
171 | 169 | ||
172 | if (0 == memcmp (peer, &p1->id, sizeof (struct GNUNET_PeerIdentity))) | 170 | if (0 == memcmp (peer, &p1->id, sizeof (struct GNUNET_PeerIdentity))) |
173 | t = p1; | 171 | t = p1; |
@@ -223,19 +221,7 @@ notify_receive (void *cls, const struct GNUNET_PeerIdentity *peer, | |||
223 | "Delayed message was not delayed correctly: took only %llu\n", | 221 | "Delayed message was not delayed correctly: took only %llu\n", |
224 | (long long unsigned int) dur_delayed.rel_value); | 222 | (long long unsigned int) dur_delayed.rel_value); |
225 | } | 223 | } |
226 | for (c = 0; c < ats_count; c++) | 224 | |
227 | { | ||
228 | if (ntohl (ats[c].type) == GNUNET_ATS_QUALITY_NET_DISTANCE) | ||
229 | { | ||
230 | if (ntohl (ats[c].value) == 10) | ||
231 | ok += 0; | ||
232 | else | ||
233 | { | ||
234 | GNUNET_break (0); | ||
235 | ok += 1; | ||
236 | } | ||
237 | } | ||
238 | } | ||
239 | /* shutdown */ | 225 | /* shutdown */ |
240 | end (); | 226 | end (); |
241 | } | 227 | } |
@@ -322,8 +308,7 @@ sendtask (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc) | |||
322 | 308 | ||
323 | 309 | ||
324 | static void | 310 | static void |
325 | notify_connect (void *cls, const struct GNUNET_PeerIdentity *peer, | 311 | notify_connect (void *cls, const struct GNUNET_PeerIdentity *peer) |
326 | const struct GNUNET_ATS_Information *ats, uint32_t ats_count) | ||
327 | { | 312 | { |
328 | static int c; | 313 | static int c; |
329 | 314 | ||
diff --git a/src/transport/test_transport_api_reliability.c b/src/transport/test_transport_api_reliability.c index bef2d0ffe..2993a224d 100644 --- a/src/transport/test_transport_api_reliability.c +++ b/src/transport/test_transport_api_reliability.c | |||
@@ -188,8 +188,7 @@ get_size (unsigned int iter) | |||
188 | 188 | ||
189 | static void | 189 | static void |
190 | notify_receive (void *cls, const struct GNUNET_PeerIdentity *peer, | 190 | notify_receive (void *cls, const struct GNUNET_PeerIdentity *peer, |
191 | const struct GNUNET_MessageHeader *message, | 191 | const struct GNUNET_MessageHeader *message) |
192 | const struct GNUNET_ATS_Information *ats, uint32_t ats_count) | ||
193 | { | 192 | { |
194 | static int n; | 193 | static int n; |
195 | unsigned int s; | 194 | unsigned int s; |
@@ -346,8 +345,7 @@ notify_ready (void *cls, size_t size, void *buf) | |||
346 | 345 | ||
347 | 346 | ||
348 | static void | 347 | static void |
349 | notify_connect (void *cls, const struct GNUNET_PeerIdentity *peer, | 348 | notify_connect (void *cls, const struct GNUNET_PeerIdentity *peer) |
350 | const struct GNUNET_ATS_Information *ats, uint32_t ats_count) | ||
351 | { | 349 | { |
352 | 350 | ||
353 | struct PeerContext *p = cls; | 351 | struct PeerContext *p = cls; |
diff --git a/src/transport/test_transport_api_restart_1peer.c b/src/transport/test_transport_api_restart_1peer.c index 9927946de..8472e29c0 100644 --- a/src/transport/test_transport_api_restart_1peer.c +++ b/src/transport/test_transport_api_restart_1peer.c | |||
@@ -174,8 +174,7 @@ restart (struct PeerContext *p, char *cfg_file) | |||
174 | 174 | ||
175 | static void | 175 | static void |
176 | notify_receive (void *cls, const struct GNUNET_PeerIdentity *peer, | 176 | notify_receive (void *cls, const struct GNUNET_PeerIdentity *peer, |
177 | const struct GNUNET_MessageHeader *message, | 177 | const struct GNUNET_MessageHeader *message) |
178 | const struct GNUNET_ATS_Information *ats, uint32_t ats_count) | ||
179 | { | 178 | { |
180 | struct PeerContext *p = cls; | 179 | struct PeerContext *p = cls; |
181 | struct PeerContext *t = NULL; | 180 | struct PeerContext *t = NULL; |
@@ -281,8 +280,7 @@ sendtask (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc) | |||
281 | 280 | ||
282 | 281 | ||
283 | static void | 282 | static void |
284 | notify_connect (void *cls, const struct GNUNET_PeerIdentity *peer, | 283 | notify_connect (void *cls, const struct GNUNET_PeerIdentity *peer) |
285 | const struct GNUNET_ATS_Information *ats, uint32_t ats_count) | ||
286 | { | 284 | { |
287 | static int c; | 285 | static int c; |
288 | 286 | ||
diff --git a/src/transport/test_transport_api_restart_2peers.c b/src/transport/test_transport_api_restart_2peers.c index 6e55f5734..7c1e03991 100644 --- a/src/transport/test_transport_api_restart_2peers.c +++ b/src/transport/test_transport_api_restart_2peers.c | |||
@@ -171,8 +171,7 @@ restart (struct PeerContext *p, char *cfg_file) | |||
171 | 171 | ||
172 | static void | 172 | static void |
173 | notify_receive (void *cls, const struct GNUNET_PeerIdentity *peer, | 173 | notify_receive (void *cls, const struct GNUNET_PeerIdentity *peer, |
174 | const struct GNUNET_MessageHeader *message, | 174 | const struct GNUNET_MessageHeader *message) |
175 | const struct GNUNET_ATS_Information *ats, uint32_t ats_count) | ||
176 | { | 175 | { |
177 | struct PeerContext *p = cls; | 176 | struct PeerContext *p = cls; |
178 | struct PeerContext *t = NULL; | 177 | struct PeerContext *t = NULL; |
@@ -278,8 +277,7 @@ sendtask (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc) | |||
278 | 277 | ||
279 | 278 | ||
280 | static void | 279 | static void |
281 | notify_connect (void *cls, const struct GNUNET_PeerIdentity *peer, | 280 | notify_connect (void *cls, const struct GNUNET_PeerIdentity *peer) |
282 | const struct GNUNET_ATS_Information *ats, uint32_t ats_count) | ||
283 | { | 281 | { |
284 | static int c; | 282 | static int c; |
285 | 283 | ||
diff --git a/src/transport/test_transport_api_timeout.c b/src/transport/test_transport_api_timeout.c index 264573937..607a2e123 100644 --- a/src/transport/test_transport_api_timeout.c +++ b/src/transport/test_transport_api_timeout.c | |||
@@ -147,8 +147,7 @@ end_badly (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc) | |||
147 | 147 | ||
148 | static void | 148 | static void |
149 | notify_receive (void *cls, const struct GNUNET_PeerIdentity *peer, | 149 | notify_receive (void *cls, const struct GNUNET_PeerIdentity *peer, |
150 | const struct GNUNET_MessageHeader *message, | 150 | const struct GNUNET_MessageHeader *message) |
151 | const struct GNUNET_ATS_Information *ats, uint32_t ats_count) | ||
152 | { | 151 | { |
153 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | 152 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
154 | "Received message of type %d from peer %s!\n", | 153 | "Received message of type %d from peer %s!\n", |
@@ -156,8 +155,7 @@ notify_receive (void *cls, const struct GNUNET_PeerIdentity *peer, | |||
156 | } | 155 | } |
157 | 156 | ||
158 | static void | 157 | static void |
159 | notify_connect (void *cls, const struct GNUNET_PeerIdentity *peer, | 158 | notify_connect (void *cls, const struct GNUNET_PeerIdentity *peer) |
160 | const struct GNUNET_ATS_Information *ats, uint32_t ats_count) | ||
161 | { | 159 | { |
162 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Peer `%4s' connected to us (%p)!\n", | 160 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Peer `%4s' connected to us (%p)!\n", |
163 | GNUNET_i2s (peer), cls); | 161 | GNUNET_i2s (peer), cls); |
diff --git a/src/transport/test_transport_api_unreliability.c b/src/transport/test_transport_api_unreliability.c index 3658198bd..afc26cef7 100644 --- a/src/transport/test_transport_api_unreliability.c +++ b/src/transport/test_transport_api_unreliability.c | |||
@@ -284,8 +284,7 @@ get_bit (const char *map, unsigned int bit) | |||
284 | 284 | ||
285 | static void | 285 | static void |
286 | notify_receive (void *cls, const struct GNUNET_PeerIdentity *peer, | 286 | notify_receive (void *cls, const struct GNUNET_PeerIdentity *peer, |
287 | const struct GNUNET_MessageHeader *message, | 287 | const struct GNUNET_MessageHeader *message) |
288 | const struct GNUNET_ATS_Information *ats, uint32_t ats_count) | ||
289 | { | 288 | { |
290 | static int n; | 289 | static int n; |
291 | 290 | ||
@@ -434,8 +433,7 @@ notify_ready (void *cls, size_t size, void *buf) | |||
434 | 433 | ||
435 | 434 | ||
436 | static void | 435 | static void |
437 | notify_connect (void *cls, const struct GNUNET_PeerIdentity *peer, | 436 | notify_connect (void *cls, const struct GNUNET_PeerIdentity *peer) |
438 | const struct GNUNET_ATS_Information *ats, uint32_t ats_count) | ||
439 | { | 437 | { |
440 | 438 | ||
441 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Peer `%4s' connected to us (%p)!\n", | 439 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Peer `%4s' connected to us (%p)!\n", |
diff --git a/src/transport/test_transport_api_unreliability_constant.c b/src/transport/test_transport_api_unreliability_constant.c index cb24675c1..e5c244081 100644 --- a/src/transport/test_transport_api_unreliability_constant.c +++ b/src/transport/test_transport_api_unreliability_constant.c | |||
@@ -206,8 +206,7 @@ get_size (unsigned int iter) | |||
206 | 206 | ||
207 | static void | 207 | static void |
208 | notify_receive (void *cls, const struct GNUNET_PeerIdentity *peer, | 208 | notify_receive (void *cls, const struct GNUNET_PeerIdentity *peer, |
209 | const struct GNUNET_MessageHeader *message, | 209 | const struct GNUNET_MessageHeader *message) |
210 | const struct GNUNET_ATS_Information *ats, uint32_t ats_count) | ||
211 | { | 210 | { |
212 | static int n; | 211 | static int n; |
213 | 212 | ||
@@ -360,8 +359,7 @@ notify_ready (void *cls, size_t size, void *buf) | |||
360 | 359 | ||
361 | 360 | ||
362 | static void | 361 | static void |
363 | notify_connect (void *cls, const struct GNUNET_PeerIdentity *peer, | 362 | notify_connect (void *cls, const struct GNUNET_PeerIdentity *peer) |
364 | const struct GNUNET_ATS_Information *ats, uint32_t ats_count) | ||
365 | { | 363 | { |
366 | 364 | ||
367 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Peer `%4s' connected to us (%p)!\n", | 365 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Peer `%4s' connected to us (%p)!\n", |
diff --git a/src/transport/test_transport_startonly.c b/src/transport/test_transport_startonly.c index 8593b897c..2deb3f58b 100644 --- a/src/transport/test_transport_startonly.c +++ b/src/transport/test_transport_startonly.c | |||
@@ -80,8 +80,7 @@ end_badly (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc) | |||
80 | } | 80 | } |
81 | 81 | ||
82 | static void | 82 | static void |
83 | notify_connect (void *cls, const struct GNUNET_PeerIdentity *peer, | 83 | notify_connect (void *cls, const struct GNUNET_PeerIdentity *peer) |
84 | const struct GNUNET_ATS_Information *ats, uint32_t ats_count) | ||
85 | { | 84 | { |
86 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Peer `%s' connected \n", | 85 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Peer `%s' connected \n", |
87 | GNUNET_i2s (peer)); | 86 | GNUNET_i2s (peer)); |
diff --git a/src/transport/test_transport_testing.c b/src/transport/test_transport_testing.c index 95e7f22fc..747168b17 100644 --- a/src/transport/test_transport_testing.c +++ b/src/transport/test_transport_testing.c | |||
@@ -97,8 +97,7 @@ testing_connect_cb (struct PeerContext *p1, struct PeerContext *p2, void *cls) | |||
97 | } | 97 | } |
98 | 98 | ||
99 | static void | 99 | static void |
100 | notify_connect (void *cls, const struct GNUNET_PeerIdentity *peer, | 100 | notify_connect (void *cls, const struct GNUNET_PeerIdentity *peer) |
101 | const struct GNUNET_ATS_Information *ats, uint32_t ats_count) | ||
102 | { | 101 | { |
103 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Peer `%s' connected \n", | 102 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Peer `%s' connected \n", |
104 | GNUNET_i2s (peer)); | 103 | GNUNET_i2s (peer)); |
diff --git a/src/transport/transport-testing.c b/src/transport/transport-testing.c index bb0b86077..8875afb8e 100644 --- a/src/transport/transport-testing.c +++ b/src/transport/transport-testing.c | |||
@@ -67,8 +67,7 @@ find_connecting_context (struct GNUNET_TRANSPORT_TESTING_handle *tth, | |||
67 | 67 | ||
68 | 68 | ||
69 | static void | 69 | static void |
70 | notify_connect (void *cls, const struct GNUNET_PeerIdentity *peer, | 70 | notify_connect (void *cls, const struct GNUNET_PeerIdentity *peer) |
71 | const struct GNUNET_ATS_Information *ats, uint32_t ats_count) | ||
72 | { | 71 | { |
73 | struct PeerContext *p = cls; | 72 | struct PeerContext *p = cls; |
74 | char *p2_s; | 73 | char *p2_s; |
@@ -78,7 +77,7 @@ notify_connect (void *cls, const struct GNUNET_PeerIdentity *peer, | |||
78 | GNUNET_assert (NULL != p->tth); | 77 | GNUNET_assert (NULL != p->tth); |
79 | p2 = find_peer_context (p->tth, peer); | 78 | p2 = find_peer_context (p->tth, peer); |
80 | if (p->nc != NULL) | 79 | if (p->nc != NULL) |
81 | p->nc (p->cb_cls, peer, ats, ats_count); | 80 | p->nc (p->cb_cls, peer); |
82 | 81 | ||
83 | if (p2 != NULL) | 82 | if (p2 != NULL) |
84 | GNUNET_asprintf (&p2_s, "%u (`%s')", p2->no, GNUNET_i2s (&p2->id)); | 83 | GNUNET_asprintf (&p2_s, "%u (`%s')", p2->no, GNUNET_i2s (&p2->id)); |
diff --git a/src/transport/transport_api.c b/src/transport/transport_api.c index 48285302a..8dc4c7a42 100644 --- a/src/transport/transport_api.c +++ b/src/transport/transport_api.c | |||
@@ -550,7 +550,7 @@ demultiplexer (void *cls, const struct GNUNET_MessageHeader *msg) | |||
550 | "CONNECT", GNUNET_i2s (&cim->id), ntohl (cim->quota_out.value__)); | 550 | "CONNECT", GNUNET_i2s (&cim->id), ntohl (cim->quota_out.value__)); |
551 | GNUNET_BANDWIDTH_tracker_update_quota (&n->out_tracker, cim->quota_out); | 551 | GNUNET_BANDWIDTH_tracker_update_quota (&n->out_tracker, cim->quota_out); |
552 | if (h->nc_cb != NULL) | 552 | if (h->nc_cb != NULL) |
553 | h->nc_cb (h->cls, &n->id, NULL, 0); | 553 | h->nc_cb (h->cls, &n->id); |
554 | break; | 554 | break; |
555 | case GNUNET_MESSAGE_TYPE_TRANSPORT_DISCONNECT: | 555 | case GNUNET_MESSAGE_TYPE_TRANSPORT_DISCONNECT: |
556 | if (size != sizeof (struct DisconnectInfoMessage)) | 556 | if (size != sizeof (struct DisconnectInfoMessage)) |