mirror of
https://github.com/curl/curl.git
synced 2026-07-26 00:57:15 +03:00
checksrc: warn for assignments within if() expressions
... they're already frowned upon in our source code style guide, this now enforces the rule harder.
This commit is contained in:
parent
b228d2952b
commit
1c3e8bbfed
86 changed files with 413 additions and 226 deletions
|
|
@ -124,9 +124,14 @@ void ourWriteOut(CURL *curl, struct OutStruct *outs, const char *writeinfo)
|
|||
char *end;
|
||||
char keepit;
|
||||
int i;
|
||||
if(('{' == ptr[1]) && ((end = strchr(ptr, '}')) != NULL)) {
|
||||
if('{' == ptr[1]) {
|
||||
bool match = FALSE;
|
||||
end = strchr(ptr, '}');
|
||||
ptr += 2; /* pass the % and the { */
|
||||
if(!end) {
|
||||
fputs("%{", stream);
|
||||
continue;
|
||||
}
|
||||
keepit = *end;
|
||||
*end = 0; /* zero terminate */
|
||||
for(i = 0; replacements[i].name; i++) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue