mirror of
https://github.com/curl/curl.git
synced 2024-11-21 01:16:58 +08:00
pipeline: move function to pipeline.c and make static
... as it was only used from there.
This commit is contained in:
parent
e91aedd840
commit
591a6933da
@ -91,6 +91,15 @@ bool Curl_pipeline_penalized(struct SessionHandle *data,
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
static CURLcode addHandleToPipeline(struct SessionHandle *data,
|
||||
struct curl_llist *pipeline)
|
||||
{
|
||||
if(!Curl_llist_insert_next(pipeline, pipeline->tail, data))
|
||||
return CURLE_OUT_OF_MEMORY;
|
||||
return CURLE_OK;
|
||||
}
|
||||
|
||||
|
||||
CURLcode Curl_add_handle_to_pipeline(struct SessionHandle *handle,
|
||||
struct connectdata *conn)
|
||||
{
|
||||
@ -100,7 +109,7 @@ CURLcode Curl_add_handle_to_pipeline(struct SessionHandle *handle,
|
||||
|
||||
pipeline = conn->send_pipe;
|
||||
|
||||
result = Curl_addHandleToPipeline(handle, pipeline);
|
||||
result = addHandleToPipeline(handle, pipeline);
|
||||
|
||||
if(pipeline == conn->send_pipe && sendhead != conn->send_pipe->head) {
|
||||
/* this is a new one as head, expire it */
|
||||
|
@ -2835,14 +2835,6 @@ bool Curl_isPipeliningEnabled(const struct SessionHandle *handle)
|
||||
return Curl_multi_pipeline_enabled(handle->multi);
|
||||
}
|
||||
|
||||
CURLcode Curl_addHandleToPipeline(struct SessionHandle *data,
|
||||
struct curl_llist *pipeline)
|
||||
{
|
||||
if(!Curl_llist_insert_next(pipeline, pipeline->tail, data))
|
||||
return CURLE_OUT_OF_MEMORY;
|
||||
return CURLE_OK;
|
||||
}
|
||||
|
||||
int Curl_removeHandleFromPipeline(struct SessionHandle *handle,
|
||||
struct curl_llist *pipeline)
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user