aboutsummaryrefslogtreecommitdiff
path: root/src/testing_old/testing_group.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/testing_old/testing_group.c')
-rw-r--r--src/testing_old/testing_group.c36
1 files changed, 18 insertions, 18 deletions
diff --git a/src/testing_old/testing_group.c b/src/testing_old/testing_group.c
index b9bdc66c2..086ce2720 100644
--- a/src/testing_old/testing_group.c
+++ b/src/testing_old/testing_group.c
@@ -1037,9 +1037,9 @@ struct ProgressMeter
1037 * @param hash set to uid (extended with zeros) 1037 * @param hash set to uid (extended with zeros)
1038 */ 1038 */
1039static void 1039static void
1040hash_from_uid (uint32_t uid, GNUNET_HashCode * hash) 1040hash_from_uid (uint32_t uid, struct GNUNET_HashCode * hash)
1041{ 1041{
1042 memset (hash, 0, sizeof (GNUNET_HashCode)); 1042 memset (hash, 0, sizeof (struct GNUNET_HashCode));
1043 *((uint32_t *) hash) = uid; 1043 *((uint32_t *) hash) = uid;
1044} 1044}
1045 1045
@@ -1050,7 +1050,7 @@ hash_from_uid (uint32_t uid, GNUNET_HashCode * hash)
1050 * @param hash set to uid (extended with zeros) 1050 * @param hash set to uid (extended with zeros)
1051 */ 1051 */
1052static void 1052static void
1053uid_from_hash (const GNUNET_HashCode * hash, uint32_t * uid) 1053uid_from_hash (const struct GNUNET_HashCode * hash, uint32_t * uid)
1054{ 1054{
1055 memcpy (uid, hash, sizeof (uint32_t)); 1055 memcpy (uid, hash, sizeof (uint32_t));
1056} 1056}
@@ -1579,8 +1579,8 @@ remove_connections (struct GNUNET_TESTING_PeerGroup *pg, unsigned int first,
1579 struct PeerConnection **second_tail; 1579 struct PeerConnection **second_tail;
1580 1580
1581#else 1581#else
1582 GNUNET_HashCode hash_first; 1582 struct GNUNET_HashCode hash_first;
1583 GNUNET_HashCode hash_second; 1583 struct GNUNET_HashCode hash_second;
1584 1584
1585 hash_from_uid (first, &hash_first); 1585 hash_from_uid (first, &hash_first);
1586 hash_from_uid (second, &hash_second); 1586 hash_from_uid (second, &hash_second);
@@ -2470,7 +2470,7 @@ create_clique (struct GNUNET_TESTING_PeerGroup *pg,
2470 * GNUNET_NO if not. 2470 * GNUNET_NO if not.
2471 */ 2471 */
2472static int 2472static int
2473unblacklist_iterator (void *cls, const GNUNET_HashCode * key, void *value) 2473unblacklist_iterator (void *cls, const struct GNUNET_HashCode * key, void *value)
2474{ 2474{
2475 struct UnblacklistContext *un_ctx = cls; 2475 struct UnblacklistContext *un_ctx = cls;
2476 uint32_t second_pos; 2476 uint32_t second_pos;
@@ -2760,7 +2760,7 @@ create_ring (struct GNUNET_TESTING_PeerGroup *pg,
2760 * "fixing" now. 2760 * "fixing" now.
2761 */ 2761 */
2762static int 2762static int
2763friend_file_iterator (void *cls, const GNUNET_HashCode * key, void *value) 2763friend_file_iterator (void *cls, const struct GNUNET_HashCode * key, void *value)
2764{ 2764{
2765 FILE *temp_friend_handle = cls; 2765 FILE *temp_friend_handle = cls;
2766 struct GNUNET_TESTING_Daemon *peer = value; 2766 struct GNUNET_TESTING_Daemon *peer = value;
@@ -2797,7 +2797,7 @@ struct BlacklistContext
2797 * @return GNUNET_YES to continue iteration 2797 * @return GNUNET_YES to continue iteration
2798 */ 2798 */
2799static int 2799static int
2800blacklist_file_iterator (void *cls, const GNUNET_HashCode * key, void *value) 2800blacklist_file_iterator (void *cls, const struct GNUNET_HashCode * key, void *value)
2801{ 2801{
2802 struct BlacklistContext *blacklist_ctx = cls; 2802 struct BlacklistContext *blacklist_ctx = cls;
2803 struct GNUNET_TESTING_Daemon *peer = value; 2803 struct GNUNET_TESTING_Daemon *peer = value;
@@ -3682,7 +3682,7 @@ schedule_connect (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc)
3682 * @return GNUNET_YES to continue iteration 3682 * @return GNUNET_YES to continue iteration
3683 */ 3683 */
3684static int 3684static int
3685connect_iterator (void *cls, const GNUNET_HashCode * key, void *value) 3685connect_iterator (void *cls, const struct GNUNET_HashCode * key, void *value)
3686{ 3686{
3687 struct ConnectTopologyContext *ct_ctx = cls; 3687 struct ConnectTopologyContext *ct_ctx = cls;
3688 struct PeerData *first = ct_ctx->first; 3688 struct PeerData *first = ct_ctx->first;
@@ -3713,7 +3713,7 @@ connect_iterator (void *cls, const GNUNET_HashCode * key, void *value)
3713 * @return GNUNET_YES to continue iteration 3713 * @return GNUNET_YES to continue iteration
3714 */ 3714 */
3715static int 3715static int
3716copy_topology_iterator (void *cls, const GNUNET_HashCode * key, void *value) 3716copy_topology_iterator (void *cls, const struct GNUNET_HashCode * key, void *value)
3717{ 3717{
3718 struct PeerData *first = cls; 3718 struct PeerData *first = cls;
3719 3719
@@ -4108,12 +4108,12 @@ GNUNET_TESTING_create_topology (struct GNUNET_TESTING_PeerGroup *pg,
4108 * @return GNUNET_YES to continue iteration 4108 * @return GNUNET_YES to continue iteration
4109 */ 4109 */
4110static int 4110static int
4111random_connect_iterator (void *cls, const GNUNET_HashCode * key, void *value) 4111random_connect_iterator (void *cls, const struct GNUNET_HashCode * key, void *value)
4112{ 4112{
4113 struct RandomContext *random_ctx = cls; 4113 struct RandomContext *random_ctx = cls;
4114 double random_number; 4114 double random_number;
4115 uint32_t second_pos; 4115 uint32_t second_pos;
4116 GNUNET_HashCode first_hash; 4116 struct GNUNET_HashCode first_hash;
4117 4117
4118 random_number = 4118 random_number =
4119 ((double) 4119 ((double)
@@ -4153,11 +4153,11 @@ random_connect_iterator (void *cls, const GNUNET_HashCode * key, void *value)
4153 * @return GNUNET_YES to continue iteration 4153 * @return GNUNET_YES to continue iteration
4154 */ 4154 */
4155static int 4155static int
4156minimum_connect_iterator (void *cls, const GNUNET_HashCode * key, void *value) 4156minimum_connect_iterator (void *cls, const struct GNUNET_HashCode * key, void *value)
4157{ 4157{
4158 struct MinimumContext *min_ctx = cls; 4158 struct MinimumContext *min_ctx = cls;
4159 uint32_t second_pos; 4159 uint32_t second_pos;
4160 GNUNET_HashCode first_hash; 4160 struct GNUNET_HashCode first_hash;
4161 unsigned int i; 4161 unsigned int i;
4162 4162
4163 if (GNUNET_CONTAINER_multihashmap_size 4163 if (GNUNET_CONTAINER_multihashmap_size
@@ -4211,10 +4211,10 @@ minimum_connect_iterator (void *cls, const GNUNET_HashCode * key, void *value)
4211 * @return GNUNET_YES to continue iteration 4211 * @return GNUNET_YES to continue iteration
4212 */ 4212 */
4213static int 4213static int
4214dfs_connect_iterator (void *cls, const GNUNET_HashCode * key, void *value) 4214dfs_connect_iterator (void *cls, const struct GNUNET_HashCode * key, void *value)
4215{ 4215{
4216 struct DFSContext *dfs_ctx = cls; 4216 struct DFSContext *dfs_ctx = cls;
4217 GNUNET_HashCode first_hash; 4217 struct GNUNET_HashCode first_hash;
4218 4218
4219 if (dfs_ctx->current == dfs_ctx->chosen) 4219 if (dfs_ctx->current == dfs_ctx->chosen)
4220 { 4220 {
@@ -4538,7 +4538,7 @@ struct FindClosestContext
4538 * GNUNET_NO if not. 4538 * GNUNET_NO if not.
4539 */ 4539 */
4540static int 4540static int
4541find_closest_peers (void *cls, const GNUNET_HashCode * key, void *value) 4541find_closest_peers (void *cls, const struct GNUNET_HashCode * key, void *value)
4542{ 4542{
4543 struct FindClosestContext *closest_ctx = cls; 4543 struct FindClosestContext *closest_ctx = cls;
4544 struct GNUNET_TESTING_Daemon *daemon = value; 4544 struct GNUNET_TESTING_Daemon *daemon = value;
@@ -4627,7 +4627,7 @@ perform_dfs (struct GNUNET_TESTING_PeerGroup *pg, unsigned int num)
4627 struct PeerConnection *peer_iter; 4627 struct PeerConnection *peer_iter;
4628#else 4628#else
4629 struct DFSContext dfs_ctx; 4629 struct DFSContext dfs_ctx;
4630 GNUNET_HashCode second_hash; 4630 struct GNUNET_HashCode second_hash;
4631#endif 4631#endif
4632 4632
4633#if OLD 4633#if OLD