diff --git a/include/struct.h b/include/struct.h index c70f6ea..692258c 100644 --- a/include/struct.h +++ b/include/struct.h @@ -1038,7 +1038,7 @@ typedef struct timerlist_stru struct timerlist_stru *next; char ref[REFNUM_MAX + 1]; unsigned long refno; -struct timeval time; + struct timeval time; int (*callback) (void *, char *); char *command; char *subargs; @@ -1047,7 +1047,6 @@ struct timeval time; int server; int window; char *whom; - int delete; } TimerList; typedef struct nicktab_stru diff --git a/include/timer.h b/include/timer.h index 8f9b2de..26fa4ea 100644 --- a/include/timer.h +++ b/include/timer.h @@ -10,8 +10,6 @@ extern void timercmd (char *, char *, char *, char *); extern void ExecuteTimers (void); extern char *BX_add_timer (int, char *, double, long, int (*) (void *, char *), char *, char *, int, char *); extern int BX_delete_timer (char *); -extern int get_delete_timer(char *); -extern int kill_timer(char *); extern void BX_delete_all_timers (void); extern int timer_exists (char *ref); diff --git a/source/timer.c b/source/timer.c index 7ad222b..a9248c6 100644 --- a/source/timer.c +++ b/source/timer.c @@ -247,14 +247,6 @@ extern void ExecuteTimers (void) break; } } - if (current && current->delete) - { - if (!current->callback) - new_free(¤t->command); - new_free(¤t->subargs); - new_free(¤t->whom); - new_free(¤t); - } } parsingtimer = 0; } @@ -376,34 +368,6 @@ extern int BX_delete_timer (char *ref) return -1; } -int kill_timer(char *ref) -{ - TimerList *tmp; - for (tmp = PendingTimers; tmp; tmp = tmp->next) - { - /* can only delete user created timers */ - if (!my_stricmp(tmp->ref, ref)) - { - tmp->delete = 1; - return 0; - } - } - return -1; -} - -int get_delete_timer(char *ref) -{ - TimerList *tmp; - for (tmp = PendingTimers; tmp; tmp = tmp->next) - { - /* can only delete user created timers */ - if (!my_stricmp(tmp->ref, ref)) - return tmp->delete; - } - return -1; - -} - void BX_delete_all_timers (void) { while (PendingTimers)