mirror of
https://github.com/curl/curl.git
synced 2026-08-25 21:53:32 +03:00
lib: fix formatting nits (part 3)
From `lib/h` to `lib/w`. part 1:47a1ab2ebe#19764 part 2:86b346443b#19800 Closes #19811
This commit is contained in:
parent
dc8c0d54a5
commit
c3b030b860
102 changed files with 2001 additions and 2226 deletions
|
|
@ -82,7 +82,7 @@
|
|||
#include "curlx/warnless.h"
|
||||
|
||||
#if !defined(CURL_DISABLE_HTTP) || !defined(CURL_DISABLE_SMTP) || \
|
||||
!defined(CURL_DISABLE_IMAP)
|
||||
!defined(CURL_DISABLE_IMAP)
|
||||
/*
|
||||
* checkheaders() checks the linked list of custom headers for a
|
||||
* particular header (prefix). Provide the prefix without colon!
|
||||
|
|
@ -95,11 +95,11 @@ char *Curl_checkheaders(const struct Curl_easy *data,
|
|||
{
|
||||
struct curl_slist *head;
|
||||
DEBUGASSERT(thislen);
|
||||
DEBUGASSERT(thisheader[thislen-1] != ':');
|
||||
DEBUGASSERT(thisheader[thislen - 1] != ':');
|
||||
|
||||
for(head = data->set.headers; head; head = head->next) {
|
||||
if(curl_strnequal(head->data, thisheader, thislen) &&
|
||||
Curl_headersep(head->data[thislen]) )
|
||||
Curl_headersep(head->data[thislen]))
|
||||
return head->data;
|
||||
}
|
||||
|
||||
|
|
@ -111,13 +111,13 @@ static int data_pending(struct Curl_easy *data, bool rcvd_eagain)
|
|||
{
|
||||
struct connectdata *conn = data->conn;
|
||||
|
||||
if(conn->handler->protocol&PROTO_FAMILY_FTP)
|
||||
if(conn->handler->protocol & PROTO_FAMILY_FTP)
|
||||
return Curl_conn_data_pending(data, SECONDARYSOCKET);
|
||||
|
||||
/* in the case of libssh2, we can never be really sure that we have emptied
|
||||
its internal buffers so we MUST always try until we get EAGAIN back */
|
||||
return (!rcvd_eagain &&
|
||||
conn->handler->protocol&(CURLPROTO_SCP|CURLPROTO_SFTP)) ||
|
||||
conn->handler->protocol & (CURLPROTO_SCP | CURLPROTO_SFTP)) ||
|
||||
Curl_conn_data_pending(data, FIRSTSOCKET);
|
||||
}
|
||||
|
||||
|
|
@ -329,7 +329,7 @@ static CURLcode sendrecv_dl(struct Curl_easy *data,
|
|||
CURL_TRC_M(data, "sendrecv_dl() no EAGAIN/pending data, mark as dirty");
|
||||
}
|
||||
|
||||
if(((k->keepon & (KEEP_RECV|KEEP_SEND)) == KEEP_SEND) &&
|
||||
if(((k->keepon & (KEEP_RECV | KEEP_SEND)) == KEEP_SEND) &&
|
||||
(conn->bits.close || is_multiplex)) {
|
||||
/* When we have read the entire thing and the close bit is set, the server
|
||||
may now close the connection. If there is now any kind of sending going
|
||||
|
|
@ -428,7 +428,7 @@ CURLcode Curl_sendrecv(struct Curl_easy *data, struct curltime *nowp)
|
|||
}
|
||||
|
||||
/* If there is nothing more to send/recv, the request is done */
|
||||
if((k->keepon & (KEEP_RECV|KEEP_SEND)) == 0)
|
||||
if((k->keepon & (KEEP_RECV | KEEP_SEND)) == 0)
|
||||
data->req.done = TRUE;
|
||||
|
||||
result = Curl_pgrsUpdate(data);
|
||||
|
|
@ -636,7 +636,7 @@ CURLcode Curl_retry_request(struct Curl_easy *data, char **url)
|
|||
protocol is HTTP as when uploading over HTTP we will still get a
|
||||
response */
|
||||
if(data->state.upload &&
|
||||
!(conn->handler->protocol&(PROTO_FAMILY_HTTP|CURLPROTO_RTSP)))
|
||||
!(conn->handler->protocol & (PROTO_FAMILY_HTTP | CURLPROTO_RTSP)))
|
||||
return CURLE_OK;
|
||||
|
||||
if(conn->bits.reuse &&
|
||||
|
|
@ -656,7 +656,7 @@ CURLcode Curl_retry_request(struct Curl_easy *data, char **url)
|
|||
it again. Bad luck. Retry the same request on a fresh connect! */
|
||||
retry = TRUE;
|
||||
else if(data->state.refused_stream &&
|
||||
(data->req.bytecount + data->req.headerbytecount == 0) ) {
|
||||
(data->req.bytecount + data->req.headerbytecount == 0)) {
|
||||
/* This was sent on a refused stream, safe to rerun. A refused stream
|
||||
error can typically only happen on HTTP/2 level if the stream is safe
|
||||
to issue again, but the nghttp2 API can deliver the message to other
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue