mirror of
https://github.com/curl/curl.git
synced 2026-08-25 07:43: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
15
lib/sendf.c
15
lib/sendf.c
|
|
@ -69,13 +69,14 @@ CURLcode Curl_client_write(struct Curl_easy *data,
|
|||
CURLcode result;
|
||||
|
||||
/* it is one of those, at least */
|
||||
DEBUGASSERT(type & (CLIENTWRITE_BODY|CLIENTWRITE_HEADER|CLIENTWRITE_INFO));
|
||||
DEBUGASSERT(type &
|
||||
(CLIENTWRITE_BODY | CLIENTWRITE_HEADER | CLIENTWRITE_INFO));
|
||||
/* BODY is only BODY (with optional EOS) */
|
||||
DEBUGASSERT(!(type & CLIENTWRITE_BODY) ||
|
||||
((type & ~(CLIENTWRITE_BODY|CLIENTWRITE_EOS)) == 0));
|
||||
((type & ~(CLIENTWRITE_BODY | CLIENTWRITE_EOS)) == 0));
|
||||
/* INFO is only INFO (with optional EOS) */
|
||||
DEBUGASSERT(!(type & CLIENTWRITE_INFO) ||
|
||||
((type & ~(CLIENTWRITE_INFO|CLIENTWRITE_EOS)) == 0));
|
||||
((type & ~(CLIENTWRITE_INFO | CLIENTWRITE_EOS)) == 0));
|
||||
|
||||
if(!data->req.writer_stack) {
|
||||
result = do_init_writer_stack(data);
|
||||
|
|
@ -227,7 +228,7 @@ static CURLcode cw_download_write(struct Curl_easy *data,
|
|||
bool is_connect = !!(type & CLIENTWRITE_CONNECT);
|
||||
|
||||
if(!ctx->started_response &&
|
||||
!(type & (CLIENTWRITE_INFO|CLIENTWRITE_CONNECT))) {
|
||||
!(type & (CLIENTWRITE_INFO | CLIENTWRITE_CONNECT))) {
|
||||
Curl_pgrsTime(data, TIMER_STARTTRANSFER);
|
||||
Curl_rlimit_start(&data->progress.dl.rlimit, curlx_now());
|
||||
ctx->started_response = TRUE;
|
||||
|
|
@ -784,7 +785,7 @@ static CURLcode cr_in_resume_from(struct Curl_easy *data,
|
|||
}
|
||||
/* when seekerr == CURL_SEEKFUNC_CANTSEEK (cannot seek to offset) */
|
||||
do {
|
||||
char scratch[4*1024];
|
||||
char scratch[4 * 1024];
|
||||
size_t readthisamountnow =
|
||||
(offset - passed > (curl_off_t)sizeof(scratch)) ?
|
||||
sizeof(scratch) :
|
||||
|
|
@ -1089,8 +1090,7 @@ static CURLcode cr_lc_add(struct Curl_easy *data)
|
|||
struct Curl_creader *reader = NULL;
|
||||
CURLcode result;
|
||||
|
||||
result = Curl_creader_create(&reader, data, &cr_lc,
|
||||
CURL_CR_CONTENT_ENCODE);
|
||||
result = Curl_creader_create(&reader, data, &cr_lc, CURL_CR_CONTENT_ENCODE);
|
||||
if(!result)
|
||||
result = Curl_creader_add(data, reader);
|
||||
|
||||
|
|
@ -1481,5 +1481,4 @@ struct Curl_creader *Curl_creader_get_by_type(struct Curl_easy *data,
|
|||
return r;
|
||||
}
|
||||
return NULL;
|
||||
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue