From: Christian Ruppert Date: Fri, 23 Apr 2010 17:27:34 +0000 (+0000) Subject: Move function declarations to fix compiler warning: X-Git-Url: https://git.brokenzipper.com/gitweb?a=commitdiff_plain;h=8a66c780e7fc932563b427999c3c6c2e923b232b;p=chaz%2Ftint2 Move function declarations to fix compiler warning: util/timer.c:81: warning: conflicting types for ‘stop_multi_timeout’ util/timer.c:61: note: previous implicit declaration of ‘stop_multi_timeout’ was here --- diff --git a/src/util/timer.c b/src/util/timer.c index b4db7f4..8d22082 100644 --- a/src/util/timer.c +++ b/src/util/timer.c @@ -46,6 +46,21 @@ struct _timeout { multi_timeout* multi_timeout; }; +void add_timeout_intern(int value_msec, int interval_msec, void(*_callback)(void*), void* arg, timeout* t); +gint compare_timeouts(gconstpointer t1, gconstpointer t2); +gint compare_timespecs(const struct timespec* t1, const struct timespec* t2); +int timespec_subtract(struct timespec* result, struct timespec* x, struct timespec* y); +struct timespec add_msec_to_timespec(struct timespec ts, int msec); + + +int align_with_existing_timeouts(timeout* t); +void create_multi_timeout(timeout* t1, timeout* t2); +void append_multi_timeout(timeout* t1, timeout* t2); +int calc_multi_timeout_interval(multi_timeout_handler* mth); +void update_multi_timeout_values(multi_timeout_handler* mth); +void callback_multi_timeout(void* mth); +void remove_from_multi_timeout(timeout* t); +void stop_multi_timeout(timeout* t); void default_timeout() { @@ -64,22 +79,6 @@ void cleanup_timeout() } } -void add_timeout_intern(int value_msec, int interval_msec, void(*_callback)(void*), void* arg, timeout* t); -gint compare_timeouts(gconstpointer t1, gconstpointer t2); -gint compare_timespecs(const struct timespec* t1, const struct timespec* t2); -int timespec_subtract(struct timespec* result, struct timespec* x, struct timespec* y); -struct timespec add_msec_to_timespec(struct timespec ts, int msec); - - -int align_with_existing_timeouts(timeout* t); -void create_multi_timeout(timeout* t1, timeout* t2); -void append_multi_timeout(timeout* t1, timeout* t2); -int calc_multi_timeout_interval(multi_timeout_handler* mth); -void update_multi_timeout_values(multi_timeout_handler* mth); -void callback_multi_timeout(void* mth); -void remove_from_multi_timeout(timeout* t); -void stop_multi_timeout(timeout* t); - /** Implementation notes for timeouts: The timeouts are kept in a GSList sorted by their * expiration time. * That means that update_next_timeout() only have to consider the first timeout in the list,