mirror of
https://github.com/curl/curl.git
synced 2026-08-26 21:44:10 +03:00
infof: remove newline from format strings, always append it
- the data needs to be "line-based" anyway since it's also passed to the debug callback/application - it makes infof() work like failf() and consistency is good - there's an assert that triggers on newlines in the format string - Also removes a few instances of "..." - Removes the code that would append "..." to the end of the data *iff* it was truncated in infof() Closes #7357
This commit is contained in:
parent
1026b36ea0
commit
e7416cfd2b
69 changed files with 936 additions and 947 deletions
12
lib/telnet.c
12
lib/telnet.c
|
|
@ -268,9 +268,9 @@ static void printoption(struct Curl_easy *data,
|
|||
if(data->set.verbose) {
|
||||
if(cmd == CURL_IAC) {
|
||||
if(CURL_TELCMD_OK(option))
|
||||
infof(data, "%s IAC %s\n", direction, CURL_TELCMD(option));
|
||||
infof(data, "%s IAC %s", direction, CURL_TELCMD(option));
|
||||
else
|
||||
infof(data, "%s IAC %d\n", direction, option);
|
||||
infof(data, "%s IAC %d", direction, option);
|
||||
}
|
||||
else {
|
||||
const char *fmt = (cmd == CURL_WILL) ? "WILL" :
|
||||
|
|
@ -287,12 +287,12 @@ static void printoption(struct Curl_easy *data,
|
|||
opt = NULL;
|
||||
|
||||
if(opt)
|
||||
infof(data, "%s %s %s\n", direction, fmt, opt);
|
||||
infof(data, "%s %s %s", direction, fmt, opt);
|
||||
else
|
||||
infof(data, "%s %s %d\n", direction, fmt, option);
|
||||
infof(data, "%s %s %d", direction, fmt, option);
|
||||
}
|
||||
else
|
||||
infof(data, "%s %d %d\n", direction, cmd, option);
|
||||
infof(data, "%s %d %d", direction, cmd, option);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -765,8 +765,6 @@ static void printsub(struct Curl_easy *data,
|
|||
break;
|
||||
}
|
||||
}
|
||||
if(direction)
|
||||
infof(data, "\n");
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue