diff options
author | Christian Grothoff <christian@grothoff.org> | 2011-10-22 21:59:27 +0000 |
---|---|---|
committer | Christian Grothoff <christian@grothoff.org> | 2011-10-22 21:59:27 +0000 |
commit | f44c0036572d5557d2496748a4190a61e40e61ff (patch) | |
tree | bceb908e8542883ed246f96b4c619c0c49a06782 /src/testing | |
parent | 9d87d51965287d83ee332b8c50baff95bd62649a (diff) | |
download | gnunet-f44c0036572d5557d2496748a4190a61e40e61ff.tar.gz gnunet-f44c0036572d5557d2496748a4190a61e40e61ff.zip |
replacing 0-terminated atsi-array with array+length in core API (and the core-connect IPC)
Diffstat (limited to 'src/testing')
-rw-r--r-- | src/testing/test_testing_topology.c | 7 | ||||
-rw-r--r-- | src/testing/testing.c | 8 | ||||
-rw-r--r-- | src/testing/testing_group.c | 5 |
3 files changed, 14 insertions, 6 deletions
diff --git a/src/testing/test_testing_topology.c b/src/testing/test_testing_topology.c index b83a8cf3c..e563f4d64 100644 --- a/src/testing/test_testing_topology.c +++ b/src/testing/test_testing_topology.c | |||
@@ -348,7 +348,8 @@ topology_cb (void *cls, const struct GNUNET_PeerIdentity *first, | |||
348 | static int | 348 | static int |
349 | process_mtype (void *cls, const struct GNUNET_PeerIdentity *peer, | 349 | process_mtype (void *cls, const struct GNUNET_PeerIdentity *peer, |
350 | const struct GNUNET_MessageHeader *message, | 350 | const struct GNUNET_MessageHeader *message, |
351 | const struct GNUNET_ATS_Information *atsi) | 351 | const struct GNUNET_ATS_Information *atsi, |
352 | unsigned int atsi_count) | ||
352 | { | 353 | { |
353 | char *dotOutFileNameFinished; | 354 | char *dotOutFileNameFinished; |
354 | FILE *dotOutFileFinished; | 355 | FILE *dotOutFileFinished; |
@@ -537,10 +538,12 @@ init_notify_peer2 (void *cls, struct GNUNET_CORE_Handle *server, | |||
537 | * @param cls closure | 538 | * @param cls closure |
538 | * @param peer peer identity this notification is about | 539 | * @param peer peer identity this notification is about |
539 | * @param atsi performance data for the connection | 540 | * @param atsi performance data for the connection |
541 | * @param atsi_count number of records in 'atsi' | ||
540 | */ | 542 | */ |
541 | static void | 543 | static void |
542 | connect_notify_peers (void *cls, const struct GNUNET_PeerIdentity *peer, | 544 | connect_notify_peers (void *cls, const struct GNUNET_PeerIdentity *peer, |
543 | const struct GNUNET_ATS_Information *atsi) | 545 | const struct GNUNET_ATS_Information *atsi, |
546 | unsigned int atsi_count) | ||
544 | { | 547 | { |
545 | struct TestMessageContext *pos = cls; | 548 | struct TestMessageContext *pos = cls; |
546 | 549 | ||
diff --git a/src/testing/testing.c b/src/testing/testing.c index 1798a1af6..e81a92fb5 100644 --- a/src/testing/testing.c +++ b/src/testing/testing.c | |||
@@ -1882,11 +1882,13 @@ notify_connect_result (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc) | |||
1882 | * @param cls our "struct GNUNET_TESTING_ConnectContext" | 1882 | * @param cls our "struct GNUNET_TESTING_ConnectContext" |
1883 | * @param peer identity of the peer that has connected | 1883 | * @param peer identity of the peer that has connected |
1884 | * @param atsi performance information | 1884 | * @param atsi performance information |
1885 | * @param atsi_count number of records in 'atsi' | ||
1885 | * | 1886 | * |
1886 | */ | 1887 | */ |
1887 | static void | 1888 | static void |
1888 | connect_notify (void *cls, const struct GNUNET_PeerIdentity *peer, | 1889 | connect_notify (void *cls, const struct GNUNET_PeerIdentity *peer, |
1889 | const struct GNUNET_ATS_Information *atsi) | 1890 | const struct GNUNET_ATS_Information *atsi, |
1891 | unsigned int atsi_count) | ||
1890 | { | 1892 | { |
1891 | struct GNUNET_TESTING_ConnectContext *ctx = cls; | 1893 | struct GNUNET_TESTING_ConnectContext *ctx = cls; |
1892 | 1894 | ||
@@ -2080,11 +2082,13 @@ reattempt_daemons_connect (void *cls, | |||
2080 | * @param peer identity of the peer that has connected, | 2082 | * @param peer identity of the peer that has connected, |
2081 | * NULL when iteration has finished | 2083 | * NULL when iteration has finished |
2082 | * @param atsi performance information | 2084 | * @param atsi performance information |
2085 | * @param atsi_count number of records in 'atsi' | ||
2083 | * | 2086 | * |
2084 | */ | 2087 | */ |
2085 | static void | 2088 | static void |
2086 | core_initial_iteration (void *cls, const struct GNUNET_PeerIdentity *peer, | 2089 | core_initial_iteration (void *cls, const struct GNUNET_PeerIdentity *peer, |
2087 | const struct GNUNET_ATS_Information *atsi) | 2090 | const struct GNUNET_ATS_Information *atsi, |
2091 | unsigned int atsi_count) | ||
2088 | { | 2092 | { |
2089 | struct GNUNET_TESTING_ConnectContext *ctx = cls; | 2093 | struct GNUNET_TESTING_ConnectContext *ctx = cls; |
2090 | 2094 | ||
diff --git a/src/testing/testing_group.c b/src/testing/testing_group.c index a2c68c93c..04c2cfd00 100644 --- a/src/testing/testing_group.c +++ b/src/testing/testing_group.c | |||
@@ -4877,7 +4877,8 @@ perform_dfs (struct GNUNET_TESTING_PeerGroup *pg, unsigned int num) | |||
4877 | */ | 4877 | */ |
4878 | static void | 4878 | static void |
4879 | internal_topology_callback (void *cls, const struct GNUNET_PeerIdentity *peer, | 4879 | internal_topology_callback (void *cls, const struct GNUNET_PeerIdentity *peer, |
4880 | const struct GNUNET_ATS_Information *atsi) | 4880 | const struct GNUNET_ATS_Information *atsi, |
4881 | unsigned int atsi_count) | ||
4881 | { | 4882 | { |
4882 | struct CoreContext *core_ctx = cls; | 4883 | struct CoreContext *core_ctx = cls; |
4883 | struct TopologyIterateContext *iter_ctx = core_ctx->iter_context; | 4884 | struct TopologyIterateContext *iter_ctx = core_ctx->iter_context; |
@@ -4941,7 +4942,7 @@ schedule_get_topology (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc) | |||
4941 | &internal_topology_callback, core_context)) | 4942 | &internal_topology_callback, core_context)) |
4942 | { | 4943 | { |
4943 | GNUNET_log (GNUNET_ERROR_TYPE_WARNING, "Topology iteration failed.\n"); | 4944 | GNUNET_log (GNUNET_ERROR_TYPE_WARNING, "Topology iteration failed.\n"); |
4944 | internal_topology_callback (core_context, NULL, NULL); | 4945 | internal_topology_callback (core_context, NULL, NULL, 0); |
4945 | } | 4946 | } |
4946 | } | 4947 | } |
4947 | } | 4948 | } |