| 245 | } |
| 246 | |
| 247 | void |
| 248 | tmr_reset(struct timeval *nowP, Timer *t) |
| 249 | { |
| 250 | mstimeout_cache = -1; |
| 251 | t->time = *nowP; |
| 252 | t->time.tv_sec += t->msecs / 1000L; |
| 253 | t->time.tv_usec += (t->msecs % 1000L) * 1000L; |
| 254 | if (t->time.tv_usec >= 1000000L) { |
| 255 | t->time.tv_sec += t->time.tv_usec / 1000000L; |
| 256 | t->time.tv_usec %= 1000000L; |
| 257 | } |
| 258 | l_resort(t); |
| 259 | } |
| 260 | |
| 261 | void |
| 262 | tmr_cancel(Timer *t) |
no test coverage detected