aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2015-02-03 13:20:17 +0000
committerChristian Grothoff <christian@grothoff.org>2015-02-03 13:20:17 +0000
commit2aeb9884df190077944584342157afd5d32d6c8a (patch)
treeb9f1fa15b0741be6b5af46c8f50945c1e3f0a82d /src
parent8116248c35c6a085c5f3143b30ac11dc4ae53d50 (diff)
downloadgnunet-2aeb9884df190077944584342157afd5d32d6c8a.tar.gz
gnunet-2aeb9884df190077944584342157afd5d32d6c8a.zip
document API, do not pass unused 'session' argument
Diffstat (limited to 'src')
-rw-r--r--src/transport/gnunet-service-transport.c2
-rw-r--r--src/transport/gnunet-service-transport_neighbours.c35
-rw-r--r--src/transport/gnunet-service-transport_neighbours.h42
3 files changed, 64 insertions, 15 deletions
diff --git a/src/transport/gnunet-service-transport.c b/src/transport/gnunet-service-transport.c
index 936a82bb0..2f0a17360 100644
--- a/src/transport/gnunet-service-transport.c
+++ b/src/transport/gnunet-service-transport.c
@@ -428,7 +428,6 @@ GST_receive_callback (void *cls,
428 ntohs (message->size), 428 ntohs (message->size),
429 GNUNET_NO); 429 GNUNET_NO);
430 GST_neighbours_notify_data_recv (address, 430 GST_neighbours_notify_data_recv (address,
431 session,
432 message); 431 message);
433 switch (type) 432 switch (type)
434 { 433 {
@@ -522,7 +521,6 @@ GST_receive_callback (void *cls,
522 ntohs (message->size), 521 ntohs (message->size),
523 GNUNET_NO); 522 GNUNET_NO);
524 GST_neighbours_notify_payload_recv (address, 523 GST_neighbours_notify_payload_recv (address,
525 session,
526 message); 524 message);
527 ret = process_payload (address, 525 ret = process_payload (address,
528 session, 526 session,
diff --git a/src/transport/gnunet-service-transport_neighbours.c b/src/transport/gnunet-service-transport_neighbours.c
index 1ecf71517..ff3d51a4b 100644
--- a/src/transport/gnunet-service-transport_neighbours.c
+++ b/src/transport/gnunet-service-transport_neighbours.c
@@ -2916,9 +2916,16 @@ utilization_transmission (void *cls,
2916} 2916}
2917 2917
2918 2918
2919/**
2920 * Track information about data we received from the
2921 * given address (used to notify ATS about our utilization
2922 * of allocated resources).
2923 *
2924 * @param address the address we got data from
2925 * @param message the message we received (really only the size is used)
2926 */
2919void 2927void
2920GST_neighbours_notify_data_recv (const struct GNUNET_HELLO_Address *address, 2928GST_neighbours_notify_data_recv (const struct GNUNET_HELLO_Address *address,
2921 struct Session *session,
2922 const struct GNUNET_MessageHeader *message) 2929 const struct GNUNET_MessageHeader *message)
2923{ 2930{
2924 struct NeighbourMapEntry *n; 2931 struct NeighbourMapEntry *n;
@@ -2930,9 +2937,16 @@ GST_neighbours_notify_data_recv (const struct GNUNET_HELLO_Address *address,
2930} 2937}
2931 2938
2932 2939
2940/**
2941 * Track information about payload (useful data) we received from the
2942 * given address (used to notify ATS about our utilization of
2943 * allocated resources).
2944 *
2945 * @param address the address we got data from
2946 * @param message the message we received (really only the size is used)
2947 */
2933void 2948void
2934GST_neighbours_notify_payload_recv (const struct GNUNET_HELLO_Address *address, 2949GST_neighbours_notify_payload_recv (const struct GNUNET_HELLO_Address *address,
2935 struct Session *session,
2936 const struct GNUNET_MessageHeader *message) 2950 const struct GNUNET_MessageHeader *message)
2937{ 2951{
2938 struct NeighbourMapEntry *n; 2952 struct NeighbourMapEntry *n;
@@ -2944,6 +2958,15 @@ GST_neighbours_notify_payload_recv (const struct GNUNET_HELLO_Address *address,
2944} 2958}
2945 2959
2946 2960
2961/**
2962 * Track information about data we transmitted using the given @a
2963 * address and @a session (used to notify ATS about our utilization of
2964 * allocated resources).
2965 *
2966 * @param address the address we transmitted data to
2967 * @param session session we used to transmit data
2968 * @param message the message we sent (really only the size is used)
2969 */
2947void 2970void
2948GST_neighbours_notify_data_sent (const struct GNUNET_HELLO_Address *address, 2971GST_neighbours_notify_data_sent (const struct GNUNET_HELLO_Address *address,
2949 struct Session *session, 2972 struct Session *session,
@@ -2960,6 +2983,14 @@ GST_neighbours_notify_data_sent (const struct GNUNET_HELLO_Address *address,
2960} 2983}
2961 2984
2962 2985
2986/**
2987 * Track information about payload (useful data) we transmitted using the
2988 * given address (used to notify ATS about our utilization of
2989 * allocated resources).
2990 *
2991 * @param address the address we transmitted data to
2992 * @param message the message we sent (really only the size is used)
2993 */
2963void 2994void
2964GST_neighbours_notify_payload_sent (const struct GNUNET_PeerIdentity *peer, 2995GST_neighbours_notify_payload_sent (const struct GNUNET_PeerIdentity *peer,
2965 size_t size) 2996 size_t size)
diff --git a/src/transport/gnunet-service-transport_neighbours.h b/src/transport/gnunet-service-transport_neighbours.h
index 710439b10..ee3a34a79 100644
--- a/src/transport/gnunet-service-transport_neighbours.h
+++ b/src/transport/gnunet-service-transport_neighbours.h
@@ -209,38 +209,58 @@ GST_neighbours_session_terminated (const struct GNUNET_PeerIdentity *peer,
209 209
210 210
211/** 211/**
212 * FIXME 212 * Track information about data we received from the
213 * given address (used to notify ATS about our utilization
214 * of allocated resources).
215 *
216 * @param address the address we got data from
217 * @param message the message we received (really only the size is used)
213 */ 218 */
214void 219void
215GST_neighbours_notify_data_recv (const struct GNUNET_HELLO_Address *address, 220GST_neighbours_notify_data_recv (const struct GNUNET_HELLO_Address *address,
216 struct Session *session,
217 const struct GNUNET_MessageHeader *message); 221 const struct GNUNET_MessageHeader *message);
218 222
219 223
220/** 224/**
221 * FIXME 225 * Track information about payload (useful data) we received from the
226 * given address (used to notify ATS about our utilization of
227 * allocated resources).
228 *
229 * @param address the address we got data from
230 * @param message the message we received (really only the size is used)
222 */ 231 */
223void 232void
224GST_neighbours_notify_payload_recv (const struct GNUNET_HELLO_Address *address, 233GST_neighbours_notify_payload_recv (const struct GNUNET_HELLO_Address *address,
225 struct Session *session,
226 const struct GNUNET_MessageHeader *message); 234 const struct GNUNET_MessageHeader *message);
227 235
228 236
229/** 237/**
230 * FIXME 238 * Track information about data we transmitted using the given @a
239 * address and @a session (used to notify ATS about our utilization of
240 * allocated resources).
241 *
242 * @param address the address we transmitted data to
243 * @param session session we used to transmit data
244 * @param message the message we sent (really only the size is used)
231 */ 245 */
232void 246void
233GST_neighbours_notify_payload_sent (const struct GNUNET_PeerIdentity *peer, 247GST_neighbours_notify_data_sent (const struct GNUNET_HELLO_Address *address,
234 size_t size); 248 struct Session *session,
249 size_t size);
235 250
236 251
237/** 252/**
238 * FIXME 253 * Track information about payload (useful data) we transmitted using the
254 * given address (used to notify ATS about our utilization of
255 * allocated resources).
256 *
257 * @param address the address we transmitted data to
258 * @param message the message we sent (really only the size is used)
239 */ 259 */
240void 260void
241GST_neighbours_notify_data_sent (const struct GNUNET_HELLO_Address *address, 261GST_neighbours_notify_payload_sent (const struct GNUNET_PeerIdentity *peer,
242 struct Session *session, 262 size_t size);
243 size_t size); 263
244 264
245 265
246/** 266/**