diff options
author | Christian Grothoff <christian@grothoff.org> | 2013-09-26 10:54:37 +0000 |
---|---|---|
committer | Christian Grothoff <christian@grothoff.org> | 2013-09-26 10:54:37 +0000 |
commit | 9644bcee56055bbf5e1d90c1d6963d1ce7f818cc (patch) | |
tree | 813377c7cceff41cf92a57f869d095afc8084ae3 /src/util/test_common_logging_runtime_loglevels.c | |
parent | 7627b7c93947204620a2995f3fed2aca3c668a16 (diff) | |
download | gnunet-9644bcee56055bbf5e1d90c1d6963d1ce7f818cc.tar.gz gnunet-9644bcee56055bbf5e1d90c1d6963d1ce7f818cc.zip |
-minor cleanup
Diffstat (limited to 'src/util/test_common_logging_runtime_loglevels.c')
-rw-r--r-- | src/util/test_common_logging_runtime_loglevels.c | 19 |
1 files changed, 14 insertions, 5 deletions
diff --git a/src/util/test_common_logging_runtime_loglevels.c b/src/util/test_common_logging_runtime_loglevels.c index 58b722b11..37d5b2294 100644 --- a/src/util/test_common_logging_runtime_loglevels.c +++ b/src/util/test_common_logging_runtime_loglevels.c | |||
@@ -33,6 +33,7 @@ | |||
33 | #define VERBOSE GNUNET_NO | 33 | #define VERBOSE GNUNET_NO |
34 | 34 | ||
35 | static int ok; | 35 | static int ok; |
36 | |||
36 | static int phase = 0; | 37 | static int phase = 0; |
37 | 38 | ||
38 | static struct GNUNET_OS_Process *proc; | 39 | static struct GNUNET_OS_Process *proc; |
@@ -47,6 +48,7 @@ static GNUNET_SCHEDULER_TaskIdentifier read_task; | |||
47 | static void | 48 | static void |
48 | runone (void); | 49 | runone (void); |
49 | 50 | ||
51 | |||
50 | static void | 52 | static void |
51 | end_task (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc) | 53 | end_task (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc) |
52 | { | 54 | { |
@@ -82,10 +84,12 @@ end_task (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc) | |||
82 | GNUNET_log (GNUNET_ERROR_TYPE_ERROR, "failing\n"); | 84 | GNUNET_log (GNUNET_ERROR_TYPE_ERROR, "failing\n"); |
83 | } | 85 | } |
84 | 86 | ||
87 | |||
85 | static char * | 88 | static char * |
86 | read_output_line (int phase_from1, int phase_to1, int phase_from2, | 89 | read_output_line (int phase_from1, int phase_to1, int phase_from2, |
87 | int phase_to2, char c, char *expect_level, | 90 | int phase_to2, char c, const char *expect_level, |
88 | long delay_morethan, long delay_lessthan, int phase, char *p, | 91 | long delay_morethan, long delay_lessthan, int phase, |
92 | const char *p, | ||
89 | int *len, long *delay, char level[8]) | 93 | int *len, long *delay, char level[8]) |
90 | { | 94 | { |
91 | char *r = p; | 95 | char *r = p; |
@@ -161,9 +165,12 @@ read_output_line (int phase_from1, int phase_to1, int phase_from2, | |||
161 | return &r[i]; | 165 | return &r[i]; |
162 | } | 166 | } |
163 | 167 | ||
164 | char buf[20 * 16]; | 168 | static char buf[20 * 16]; |
165 | char *buf_ptr; | 169 | |
166 | int bytes; | 170 | static char *buf_ptr; |
171 | |||
172 | static int bytes; | ||
173 | |||
167 | 174 | ||
168 | static void | 175 | static void |
169 | read_call (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc) | 176 | read_call (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc) |
@@ -274,6 +281,7 @@ read_call (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc) | |||
274 | GNUNET_SCHEDULER_add_now (&end_task, NULL); | 281 | GNUNET_SCHEDULER_add_now (&end_task, NULL); |
275 | } | 282 | } |
276 | 283 | ||
284 | |||
277 | static void | 285 | static void |
278 | runone () | 286 | runone () |
279 | { | 287 | { |
@@ -356,6 +364,7 @@ runone () | |||
356 | (void*) stdout_read_handle); | 364 | (void*) stdout_read_handle); |
357 | } | 365 | } |
358 | 366 | ||
367 | |||
359 | static void | 368 | static void |
360 | task (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc) | 369 | task (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc) |
361 | { | 370 | { |