Lines Matching refs:ev

405   struct events *ev = userp;  in events_timer()  local
410 ev->ms = timeout_ms; in events_timer()
411 ev->msbump = TRUE; in events_timer()
460 struct events *ev = userp; in events_socket() local
471 m = ev->list; in events_socket()
481 ev->list = nxt; in events_socket()
510 m->next = ev->list; in events_socket()
514 ev->list = m; in events_socket()
533 static void events_setup(struct Curl_multi *multi, struct events *ev) in events_setup() argument
537 curl_multi_setopt(multi, CURLMOPT_TIMERDATA, ev); in events_setup()
541 curl_multi_setopt(multi, CURLMOPT_SOCKETDATA, ev); in events_setup()
550 static CURLcode wait_or_timeout(struct Curl_multi *multi, struct events *ev) in wait_or_timeout() argument
567 for(m = ev->list, f = &fds[0]; m; m = m->next) { in wait_or_timeout()
584 fprintf(stderr, "poll(numfds=%d, timeout=%ldms)\n", numfds, ev->ms); in wait_or_timeout()
586 pollrc = Curl_poll(fds, (unsigned int)numfds, ev->ms); in wait_or_timeout()
589 numfds, ev->ms, pollrc); in wait_or_timeout()
596 fprintf(stderr, "poll, but no fds, wait timeout=%ldms\n", ev->ms); in wait_or_timeout()
599 if(ev->ms > 0) in wait_or_timeout()
600 Curl_wait_ms(ev->ms); in wait_or_timeout()
603 ev->msbump = FALSE; /* reset here */ in wait_or_timeout()
607 ev->ms = 0; in wait_or_timeout()
610 &ev->running_handles); in wait_or_timeout()
630 &ev->running_handles); in wait_or_timeout()
635 if(!ev->msbump && ev->ms >= 0) { in wait_or_timeout()
643 "time spent %ldms\n", ev->ms, (long)timediff); in wait_or_timeout()
645 if(timediff > ev->ms) in wait_or_timeout()
646 ev->ms = 0; in wait_or_timeout()
648 ev->ms -= (long)timediff; in wait_or_timeout()