Lines Matching refs:ps

88                                  struct easy_pollset *ps)  in Curl_cf_def_adjust_pollset()  argument
93 (void)ps; in Curl_cf_def_adjust_pollset()
539 struct easy_pollset *ps) in Curl_conn_cf_adjust_pollset() argument
550 cf->cft->adjust_pollset(cf, data, ps); in Curl_conn_cf_adjust_pollset()
556 struct easy_pollset *ps) in Curl_conn_adjust_pollset() argument
563 Curl_conn_cf_adjust_pollset(data->conn->cfilter[i], data, ps); in Curl_conn_adjust_pollset()
571 struct easy_pollset ps; in Curl_conn_cf_poll() local
578 memset(&ps, 0, sizeof(ps)); in Curl_conn_cf_poll()
581 Curl_conn_cf_adjust_pollset(cf, data, &ps); in Curl_conn_cf_poll()
582 DEBUGASSERT(ps.num <= MAX_SOCKSPEREASYHANDLE); in Curl_conn_cf_poll()
583 for(i = 0; i < ps.num; ++i) { in Curl_conn_cf_poll()
585 if(ps.actions[i] & CURL_POLL_IN) { in Curl_conn_cf_poll()
588 if(ps.actions[i] & CURL_POLL_OUT) { in Curl_conn_cf_poll()
592 pfds[npfds].fd = ps.sockets[i]; in Curl_conn_cf_poll()
898 struct easy_pollset *ps) in Curl_pollset_reset() argument
902 memset(ps, 0, sizeof(*ps)); in Curl_pollset_reset()
904 ps->sockets[i] = CURL_SOCKET_BAD; in Curl_pollset_reset()
911 struct easy_pollset *ps, curl_socket_t sock, in Curl_pollset_change() argument
924 for(i = 0; i < ps->num; ++i) { in Curl_pollset_change()
925 if(ps->sockets[i] == sock) { in Curl_pollset_change()
926 ps->actions[i] &= (unsigned char)(~remove_flags); in Curl_pollset_change()
927 ps->actions[i] |= (unsigned char)add_flags; in Curl_pollset_change()
929 if(!ps->actions[i]) { in Curl_pollset_change()
930 if((i + 1) < ps->num) { in Curl_pollset_change()
931 memmove(&ps->sockets[i], &ps->sockets[i + 1], in Curl_pollset_change()
932 (ps->num - (i + 1)) * sizeof(ps->sockets[0])); in Curl_pollset_change()
933 memmove(&ps->actions[i], &ps->actions[i + 1], in Curl_pollset_change()
934 (ps->num - (i + 1)) * sizeof(ps->actions[0])); in Curl_pollset_change()
936 --ps->num; in Curl_pollset_change()
953 ps->sockets[i] = sock; in Curl_pollset_change()
954 ps->actions[i] = (unsigned char)add_flags; in Curl_pollset_change()
955 ps->num = i + 1; in Curl_pollset_change()
961 struct easy_pollset *ps, curl_socket_t sock, in Curl_pollset_set() argument
964 Curl_pollset_change(data, ps, sock, in Curl_pollset_set()
971 static void ps_add(struct Curl_easy *data, struct easy_pollset *ps, in ps_add() argument
982 Curl_pollset_add_inout(data, ps, socks[i]); in ps_add()
985 Curl_pollset_add_in(data, ps, socks[i]); in ps_add()
988 Curl_pollset_add_out(data, ps, socks[i]); in ps_add()
994 struct easy_pollset *ps, in Curl_pollset_add_socks() argument
1002 ps_add(data, ps, bitmap, socks); in Curl_pollset_add_socks()
1006 struct easy_pollset *ps, curl_socket_t sock, in Curl_pollset_check() argument
1013 for(i = 0; i < ps->num; ++i) { in Curl_pollset_check()
1014 if(ps->sockets[i] == sock) { in Curl_pollset_check()
1015 *pwant_read = !!(ps->actions[i] & CURL_POLL_IN); in Curl_pollset_check()
1016 *pwant_write = !!(ps->actions[i] & CURL_POLL_OUT); in Curl_pollset_check()