mirror of
https://github.com/curl/curl.git
synced 2026-08-05 07:26:13 +03:00
snprintf: renamed and we now only use msnprintf()
The function does not return the same value as snprintf() normally does, so readers may be mislead into thinking the code works differently than it actually does. A different function name makes this easier to detect. Reported-by: Tomas Hoger Assisted-by: Daniel Gustafsson Fixes #3296 Closes #3297
This commit is contained in:
parent
9944d6ba33
commit
dcd6f81025
92 changed files with 632 additions and 631 deletions
14
lib/multi.c
14
lib/multi.c
|
|
@ -634,13 +634,13 @@ static CURLcode multi_done(struct connectdata **connp,
|
|||
else {
|
||||
char buffer[256];
|
||||
/* create string before returning the connection */
|
||||
snprintf(buffer, sizeof(buffer),
|
||||
"Connection #%ld to host %s left intact",
|
||||
conn->connection_id,
|
||||
conn->bits.socksproxy ? conn->socks_proxy.host.dispname :
|
||||
conn->bits.httpproxy ? conn->http_proxy.host.dispname :
|
||||
conn->bits.conn_to_host ? conn->conn_to_host.dispname :
|
||||
conn->host.dispname);
|
||||
msnprintf(buffer, sizeof(buffer),
|
||||
"Connection #%ld to host %s left intact",
|
||||
conn->connection_id,
|
||||
conn->bits.socksproxy ? conn->socks_proxy.host.dispname :
|
||||
conn->bits.httpproxy ? conn->http_proxy.host.dispname :
|
||||
conn->bits.conn_to_host ? conn->conn_to_host.dispname :
|
||||
conn->host.dispname);
|
||||
|
||||
/* the connection is no longer in use by this transfer */
|
||||
if(Curl_conncache_return_conn(conn)) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue