Commit eba7275d authored by Pekka Pessi's avatar Pekka Pessi

su_timer.c: removed redundant checks

Re-recorded 20070723151500-65a35-2e24d6746b1a28f1e0c782fee864f9fcc2c041e1

darcs-hash:20090128180255-db55f-cadaccad0b30f497ac09c1ae43c787f6dbe2c861.gz
parent c26796a5
......@@ -156,7 +156,6 @@ typedef union {
*/
struct su_timer_s {
/** Pointers within red-black tree */
su_task_r sut_task; /**< Task reference */
size_t sut_heap_index; /**< Timer is set (inserted in heap) */
su_time_t sut_when; /**< When timer should be waken up next time */
......@@ -219,8 +218,6 @@ su_timer_set0(su_timer_queue_t *timers,
{
int retval;
assert(timers);
if (timers == NULL)
return -1;
......@@ -343,9 +340,6 @@ int su_timer_set_interval(su_timer_t *t,
{
su_timer_queue_t *timers = su_timer_tree(t, 0, "su_timer_set_interval");
if (t == NULL)
return -1;
return su_timer_set0(timers, t, wakeup, arg, su_now(), interval);
}
......@@ -367,9 +361,6 @@ int su_timer_set(su_timer_t *t,
{
su_timer_queue_t *timers = su_timer_tree(t, 1, "su_timer_set");
if (timers == NULL)
return -1;
return su_timer_set0(timers, t, wakeup, arg, su_now(), t->sut_duration);
}
......@@ -391,9 +382,6 @@ int su_timer_set_at(su_timer_t *t,
{
su_timer_queue_t *timers = su_timer_tree(t, 0, "su_timer_set_at");
if (timers == NULL)
return -1;
return su_timer_set0(timers, t, wakeup, arg, when, 0);
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment