mirror of
https://github.com/curl/curl.git
synced 2026-07-04 03:07:20 +03:00
clang-tidy: enable more checks, fix fallouts
- enable three checks: - bugprone-invalid-enum-default-initialization - bugprone-sizeof-expression - readability-inconsistent-declaration-parameter-name (strict) - fix remaining discrepancies with arg names in prototypes and implementation, in strict mode. - document reason for some checks tested but not enabled. Closes #20794
This commit is contained in:
parent
e0dd6eb4a4
commit
df6014894b
34 changed files with 222 additions and 209 deletions
|
|
@ -25,6 +25,6 @@
|
|||
***************************************************************************/
|
||||
#include "tool_setup.h"
|
||||
|
||||
CURLcode create_dir_hierarchy(const char *outfileo);
|
||||
CURLcode create_dir_hierarchy(const char *outfile);
|
||||
|
||||
#endif /* HEADER_CURL_TOOL_DIRHIE_H */
|
||||
|
|
|
|||
|
|
@ -294,7 +294,7 @@ ParameterError str2unummax(long *val, const char *str, long max)
|
|||
* data.
|
||||
*/
|
||||
|
||||
ParameterError secs2ms(long *valp, const char *str)
|
||||
ParameterError secs2ms(long *val, const char *str)
|
||||
{
|
||||
curl_off_t secs;
|
||||
long ms = 0;
|
||||
|
|
@ -326,7 +326,7 @@ ParameterError secs2ms(long *valp, const char *str)
|
|||
ms = ((long)fracs * 100) / digs[len - 1];
|
||||
}
|
||||
|
||||
*valp = ((long)secs * 1000) + ms;
|
||||
*val = ((long)secs * 1000) + ms;
|
||||
return PARAM_OK;
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -78,7 +78,7 @@ extern const struct NameValueUnsigned setopt_nv_CURLHSTS[];
|
|||
/* Intercept setopt calls for --libcurl */
|
||||
|
||||
CURLcode tool_setopt_enum(CURL *curl, const char *name, CURLoption tag,
|
||||
const struct NameValue *nv, long lval);
|
||||
const struct NameValue *nvlist, long lval);
|
||||
CURLcode tool_setopt_SSLVERSION(CURL *curl, const char *name, CURLoption tag,
|
||||
long lval);
|
||||
CURLcode tool_setopt_flags(CURL *curl, struct OperationConfig *config,
|
||||
|
|
@ -86,7 +86,8 @@ CURLcode tool_setopt_flags(CURL *curl, struct OperationConfig *config,
|
|||
const struct NameValue *nv, long lval);
|
||||
CURLcode tool_setopt_bitmask(CURL *curl,
|
||||
const char *name, CURLoption tag,
|
||||
const struct NameValueUnsigned *nv, long lval);
|
||||
const struct NameValueUnsigned *nvlist,
|
||||
long lval);
|
||||
CURLcode tool_setopt_mimepost(CURL *curl, struct OperationConfig *config,
|
||||
const char *name, CURLoption tag,
|
||||
curl_mime *mimepost);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue