Lines Matching refs:conn
49 struct connectdata *conn);
71 struct connectdata *conn);
80 *phost = cf->conn->host.name; in Curl_cf_def_get_host()
81 *pdisplay_host = cf->conn->host.dispname; in Curl_cf_def_get_host()
82 *pport = cf->conn->primary.remote_port; in Curl_cf_def_get_host()
167 struct connectdata *conn, int index) in Curl_conn_cf_discard_all() argument
169 Curl_conn_cf_discard_chain(&conn->cfilter[index], data); in Curl_conn_cf_discard_all()
176 DEBUGASSERT(data->conn); in Curl_conn_close()
178 cf = data->conn->cfilter[index]; in Curl_conn_close()
192 DEBUGASSERT(data->conn); in Curl_conn_shutdown()
194 cf = data->conn->cfilter[sockindex]; in Curl_conn_shutdown()
211 timeout_ms = Curl_shutdown_timeleft(data->conn, sockindex, &now); in Curl_conn_shutdown()
246 DEBUGASSERT(data->conn); in Curl_cf_recv()
248 cf = data->conn->cfilter[num]; in Curl_cf_recv()
270 DEBUGASSERT(data->conn); in Curl_cf_send()
272 cf = data->conn->cfilter[num]; in Curl_cf_send()
309 struct connectdata *conn, in Curl_conn_cf_add() argument
314 DEBUGASSERT(conn); in Curl_conn_cf_add()
315 DEBUGASSERT(!cf->conn); in Curl_conn_cf_add()
318 cf->next = conn->cfilter[index]; in Curl_conn_cf_add()
319 cf->conn = conn; in Curl_conn_cf_add()
321 conn->cfilter[index] = cf; in Curl_conn_cf_add()
332 DEBUGASSERT(!cf_new->conn); in Curl_conn_cf_insert_after()
337 cf_new->conn = cf_at->conn; in Curl_conn_cf_insert_after()
415 DEBUGASSERT(data->conn); in Curl_conn_connect()
417 cf = data->conn->cfilter[sockindex]; in Curl_conn_connect()
438 cf_cntrl_update_info(data, data->conn); in Curl_conn_connect()
439 conn_report_connect_stats(data, data->conn); in Curl_conn_connect()
440 data->conn->keepalive = Curl_now(); in Curl_conn_connect()
441 Curl_verboseconnect(data, data->conn, sockindex); in Curl_conn_connect()
444 conn_report_connect_stats(data, data->conn); in Curl_conn_connect()
451 bool Curl_conn_is_connected(struct connectdata *conn, int sockindex) in Curl_conn_is_connected() argument
455 cf = conn->cfilter[sockindex]; in Curl_conn_is_connected()
463 cf = data->conn->cfilter[sockindex]; in Curl_conn_is_ip_connected()
485 bool Curl_conn_is_ssl(struct connectdata *conn, int sockindex) in Curl_conn_is_ssl() argument
487 return conn ? Curl_conn_cf_is_ssl(conn->cfilter[sockindex]) : FALSE; in Curl_conn_is_ssl()
490 bool Curl_conn_is_multiplex(struct connectdata *conn, int sockindex) in Curl_conn_is_multiplex() argument
492 struct Curl_cfilter *cf = conn ? conn->cfilter[sockindex] : NULL; in Curl_conn_is_multiplex()
510 DEBUGASSERT(data->conn); in Curl_conn_data_pending()
512 cf = data->conn->cfilter[sockindex]; in Curl_conn_data_pending()
534 return Curl_conn_cf_needs_flush(data->conn->cfilter[sockindex], data); in Curl_conn_needs_flush()
561 DEBUGASSERT(data->conn); in Curl_conn_adjust_pollset()
563 Curl_conn_cf_adjust_pollset(data->conn->cfilter[i], data, ps); in Curl_conn_adjust_pollset()
577 DEBUGASSERT(data->conn); in Curl_conn_cf_poll()
609 DEBUGASSERT(data->conn); in Curl_conn_get_host()
610 cf = data->conn->cfilter[sockindex]; in Curl_conn_get_host()
619 *phost = data->conn->host.name; in Curl_conn_get_host()
620 *pdisplay_host = data->conn->host.dispname; in Curl_conn_get_host()
621 *pport = data->conn->remote_port; in Curl_conn_get_host()
676 cf = data->conn ? data->conn->cfilter[sockindex] : NULL; in Curl_conn_get_socket()
682 return data->conn ? data->conn->sock[sockindex] : CURL_SOCKET_BAD; in Curl_conn_get_socket()
687 if(data->conn) { in Curl_conn_forget_socket()
688 struct Curl_cfilter *cf = data->conn->cfilter[sockindex]; in Curl_conn_forget_socket()
692 fake_sclose(data->conn->sock[sockindex]); in Curl_conn_forget_socket()
693 data->conn->sock[sockindex] = CURL_SOCKET_BAD; in Curl_conn_forget_socket()
697 static CURLcode cf_cntrl_all(struct connectdata *conn, in cf_cntrl_all() argument
705 for(i = 0; i < ARRAYSIZE(conn->cfilter); ++i) { in cf_cntrl_all()
706 result = Curl_conn_cf_cntrl(conn->cfilter[i], data, ignore_result, in cf_cntrl_all()
714 void Curl_conn_ev_data_attach(struct connectdata *conn, in Curl_conn_ev_data_attach() argument
717 cf_cntrl_all(conn, data, TRUE, CF_CTRL_DATA_ATTACH, 0, NULL); in Curl_conn_ev_data_attach()
720 void Curl_conn_ev_data_detach(struct connectdata *conn, in Curl_conn_ev_data_detach() argument
723 cf_cntrl_all(conn, data, TRUE, CF_CTRL_DATA_DETACH, 0, NULL); in Curl_conn_ev_data_detach()
728 return cf_cntrl_all(data->conn, data, FALSE, in Curl_conn_ev_data_setup()
734 return cf_cntrl_all(data->conn, data, FALSE, in Curl_conn_ev_data_idle()
741 return Curl_conn_cf_cntrl(data->conn->cfilter[sockindex], data, FALSE, in Curl_conn_flush()
751 cf_cntrl_all(data->conn, data, TRUE, CF_CTRL_DATA_DONE_SEND, 0, NULL); in Curl_conn_ev_data_done_send()
760 cf_cntrl_all(data->conn, data, TRUE, CF_CTRL_DATA_DONE, premature, NULL); in Curl_conn_ev_data_done()
765 return cf_cntrl_all(data->conn, data, FALSE, in Curl_conn_ev_data_pause()
770 struct connectdata *conn) in cf_cntrl_update_info() argument
772 cf_cntrl_all(conn, data, TRUE, CF_CTRL_CONN_INFO_UPDATE, 0, NULL); in cf_cntrl_update_info()
779 struct connectdata *conn) in conn_report_connect_stats() argument
781 struct Curl_cfilter *cf = conn->cfilter[FIRSTSOCKET]; in conn_report_connect_stats()
798 bool Curl_conn_is_alive(struct Curl_easy *data, struct connectdata *conn, in Curl_conn_is_alive() argument
801 struct Curl_cfilter *cf = conn->cfilter[FIRSTSOCKET]; in Curl_conn_is_alive()
802 return cf && !cf->conn->bits.close && in Curl_conn_is_alive()
807 struct connectdata *conn, in Curl_conn_keep_alive() argument
810 struct Curl_cfilter *cf = conn->cfilter[sockindex]; in Curl_conn_keep_alive()
815 struct connectdata *conn, in Curl_conn_get_max_concurrent() argument
821 struct Curl_cfilter *cf = conn->cfilter[sockindex]; in Curl_conn_get_max_concurrent()
828 struct connectdata *conn, in Curl_conn_get_stream_error() argument
834 struct Curl_cfilter *cf = conn->cfilter[sockindex]; in Curl_conn_get_stream_error()
842 if(data && data->conn && in Curl_conn_sockindex()
843 sockfd != CURL_SOCKET_BAD && sockfd == data->conn->sock[SECONDARYSOCKET]) in Curl_conn_sockindex()
854 DEBUGASSERT(data->conn); in Curl_conn_recv()
855 nread = data->conn->recv[sockindex](data, sockindex, buf, blen, &result); in Curl_conn_recv()
869 struct connectdata *conn; in Curl_conn_send() local
874 DEBUGASSERT(data->conn); in Curl_conn_send()
875 conn = data->conn; in Curl_conn_send()
890 nwritten = conn->send[sockindex](data, sockindex, buf, write_len, eos, in Curl_conn_send()