Lines Matching defs:timeout
201 * timeout.
233 /* Wait for all `n` processes in `vec` to terminate. Time out after `timeout`
234 * msec, or never if timeout == -1. Return 0 if all processes are terminated,
235 * -1 on error, -2 on timeout. */
236 int process_wait(process_info_t* vec, int n, int timeout) {
254 /* The simple case is where there is no timeout */
255 if (timeout == -1) {
260 /* Hard case. Do the wait with a timeout.
308 if (elapsed_ms >= (unsigned) timeout)
311 tv.tv_sec = (timeout - elapsed_ms) / 1000;
312 tv.tv_usec = (timeout - elapsed_ms) % 1000 * 1000;