Lines Matching refs:conn
119 struct connectdata *conn = data->conn; in data_pending() local
121 if(conn->handler->protocol&PROTO_FAMILY_FTP) in data_pending()
126 return conn->handler->protocol&(CURLPROTO_SCP|CURLPROTO_SFTP) || in data_pending()
166 if(!data || !data->conn) in xfer_recv_shutdown()
168 if(data->conn->sockfd == CURL_SOCKET_BAD) in xfer_recv_shutdown()
170 sockindex = (data->conn->sockfd == data->conn->sock[SECONDARYSOCKET]); in xfer_recv_shutdown()
178 if(!data || !data->conn) in xfer_recv_shutdown_started()
180 if(data->conn->sockfd == CURL_SOCKET_BAD) in xfer_recv_shutdown_started()
182 sockindex = (data->conn->sockfd == data->conn->sock[SECONDARYSOCKET]); in xfer_recv_shutdown_started()
190 if(!data || !data->conn) in Curl_xfer_send_shutdown()
192 if(data->conn->writesockfd == CURL_SOCKET_BAD) in Curl_xfer_send_shutdown()
194 sockindex = (data->conn->writesockfd == data->conn->sock[SECONDARYSOCKET]); in Curl_xfer_send_shutdown()
266 struct connectdata *conn = data->conn; in sendrecv_dl() local
289 is_multiplex = Curl_conn_is_multiplex(conn, FIRSTSOCKET); in sendrecv_dl()
366 (conn->bits.close || is_multiplex)) { in sendrecv_dl()
438 if(data->conn->datastream) { in Curl_sendrecv()
439 result = data->conn->datastream(data, data->conn, &didwhat, in Curl_sendrecv()
709 struct connectdata *conn = data->conn; in Curl_retry_request() local
717 !(conn->handler->protocol&(PROTO_FAMILY_HTTP|CURLPROTO_RTSP))) in Curl_retry_request()
721 conn->bits.reuse && in Curl_retry_request()
722 (!data->req.no_body || (conn->handler->protocol & PROTO_FAMILY_HTTP)) in Curl_retry_request()
760 connclose(conn, "retry"); /* close this connection */ in Curl_retry_request()
761 conn->bits.retry = TRUE; /* mark this as a connection we are about in Curl_retry_request()
788 struct connectdata *conn = data->conn; in xfer_setup() local
791 DEBUGASSERT(conn != NULL); in xfer_setup()
796 if(conn->bits.multiplex || conn->httpversion >= 20 || want_send) { in xfer_setup()
798 conn->sockfd = sockindex == -1 ? in xfer_setup()
799 ((writesockindex == -1 ? CURL_SOCKET_BAD : conn->sock[writesockindex])) : in xfer_setup()
800 conn->sock[sockindex]; in xfer_setup()
801 conn->writesockfd = conn->sockfd; in xfer_setup()
807 conn->sockfd = sockindex == -1 ? in xfer_setup()
808 CURL_SOCKET_BAD : conn->sock[sockindex]; in xfer_setup()
809 conn->writesockfd = writesockindex == -1 ? in xfer_setup()
810 CURL_SOCKET_BAD : conn->sock[writesockindex]; in xfer_setup()
874 if(data->conn->handler->write_resp) { in Curl_xfer_write_resp()
877 result = data->conn->handler->write_resp(data, buf, blen, is_eos); in Curl_xfer_write_resp()
903 if(data->conn->handler->write_resp_hd) { in Curl_xfer_write_resp_hd()
906 return data->conn->handler->write_resp_hd(data, hd0, hdlen, is_eos); in Curl_xfer_write_resp_hd()
921 sockindex = ((data->conn->writesockfd != CURL_SOCKET_BAD) && in Curl_xfer_needs_flush()
922 (data->conn->writesockfd == data->conn->sock[SECONDARYSOCKET])); in Curl_xfer_needs_flush()
929 sockindex = ((data->conn->writesockfd != CURL_SOCKET_BAD) && in Curl_xfer_flush()
930 (data->conn->writesockfd == data->conn->sock[SECONDARYSOCKET])); in Curl_xfer_flush()
942 DEBUGASSERT(data->conn); in Curl_xfer_send()
944 sockindex = ((data->conn->writesockfd != CURL_SOCKET_BAD) && in Curl_xfer_send()
945 (data->conn->writesockfd == data->conn->sock[SECONDARYSOCKET])); in Curl_xfer_send()
966 DEBUGASSERT(data->conn); in Curl_xfer_recv()
969 sockindex = ((data->conn->sockfd != CURL_SOCKET_BAD) && in Curl_xfer_recv()
970 (data->conn->sockfd == data->conn->sock[SECONDARYSOCKET])); in Curl_xfer_recv()