diff options
author | Nathan S. Evans <evans@in.tum.de> | 2010-11-05 18:21:50 +0000 |
---|---|---|
committer | Nathan S. Evans <evans@in.tum.de> | 2010-11-05 18:21:50 +0000 |
commit | 75a33a1499cf60ea4364c9aa673816629a6c1413 (patch) | |
tree | 0620da4312bb04de4d7b65074fdd3b0c3dd6cc0e /src/core/test_core_api_start_only.c | |
parent | 7217c601ad30760872823193d62307e7a335d226 (diff) | |
download | gnunet-75a33a1499cf60ea4364c9aa673816629a6c1413.tar.gz gnunet-75a33a1499cf60ea4364c9aa673816629a6c1413.zip |
big scheduler refactoring, expect some issues
Diffstat (limited to 'src/core/test_core_api_start_only.c')
-rw-r--r-- | src/core/test_core_api_start_only.c | 9 |
1 files changed, 2 insertions, 7 deletions
diff --git a/src/core/test_core_api_start_only.c b/src/core/test_core_api_start_only.c index 958defbf9..da7217f39 100644 --- a/src/core/test_core_api_start_only.c +++ b/src/core/test_core_api_start_only.c | |||
@@ -57,7 +57,6 @@ static struct PeerContext p1; | |||
57 | 57 | ||
58 | static struct PeerContext p2; | 58 | static struct PeerContext p2; |
59 | 59 | ||
60 | static struct GNUNET_SCHEDULER_Handle *sched; | ||
61 | 60 | ||
62 | static int ok; | 61 | static int ok; |
63 | 62 | ||
@@ -126,8 +125,7 @@ init_notify (void *cls, | |||
126 | if (cls == &p1) | 125 | if (cls == &p1) |
127 | { | 126 | { |
128 | /* connect p2 */ | 127 | /* connect p2 */ |
129 | GNUNET_CORE_connect (sched, | 128 | GNUNET_CORE_connect (p2.cfg, |
130 | p2.cfg, | ||
131 | TIMEOUT, | 129 | TIMEOUT, |
132 | &p2, | 130 | &p2, |
133 | &init_notify, | 131 | &init_notify, |
@@ -166,18 +164,15 @@ setup_peer (struct PeerContext *p, const char *cfgname) | |||
166 | 164 | ||
167 | static void | 165 | static void |
168 | run (void *cls, | 166 | run (void *cls, |
169 | struct GNUNET_SCHEDULER_Handle *s, | ||
170 | char *const *args, | 167 | char *const *args, |
171 | const char *cfgfile, | 168 | const char *cfgfile, |
172 | const struct GNUNET_CONFIGURATION_Handle *cfg) | 169 | const struct GNUNET_CONFIGURATION_Handle *cfg) |
173 | { | 170 | { |
174 | GNUNET_assert (ok == 1); | 171 | GNUNET_assert (ok == 1); |
175 | OKPP; | 172 | OKPP; |
176 | sched = s; | ||
177 | setup_peer (&p1, "test_core_api_peer1.conf"); | 173 | setup_peer (&p1, "test_core_api_peer1.conf"); |
178 | setup_peer (&p2, "test_core_api_peer2.conf"); | 174 | setup_peer (&p2, "test_core_api_peer2.conf"); |
179 | GNUNET_CORE_connect (sched, | 175 | GNUNET_CORE_connect (p1.cfg, |
180 | p1.cfg, | ||
181 | TIMEOUT, | 176 | TIMEOUT, |
182 | &p1, | 177 | &p1, |
183 | &init_notify, | 178 | &init_notify, |