Родитель
ddecd28268
Коммит
26a7d51c21
|
@ -84,6 +84,7 @@ my %warnings = (
|
||||||
'TYPEDEFSTRUCT' => 'typedefed struct',
|
'TYPEDEFSTRUCT' => 'typedefed struct',
|
||||||
'DOBRACE' => 'A single space between do and open brace',
|
'DOBRACE' => 'A single space between do and open brace',
|
||||||
'BRACEWHILE' => 'A single space between open brace and while',
|
'BRACEWHILE' => 'A single space between open brace and while',
|
||||||
|
'EXCLAMATIONSPACE' => 'Whitespace after exclamation mark in expression',
|
||||||
);
|
);
|
||||||
|
|
||||||
sub readskiplist {
|
sub readskiplist {
|
||||||
|
@ -725,6 +726,12 @@ sub scanfile {
|
||||||
"typedef'ed struct");
|
"typedef'ed struct");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if($nostr =~ /(.*)! +(\w|\()/) {
|
||||||
|
checkwarn("EXCLAMATIONSPACE",
|
||||||
|
$line, length($1)+1, $file, $ol,
|
||||||
|
"space after exclamation mark");
|
||||||
|
}
|
||||||
|
|
||||||
# check for more than one consecutive space before open brace or
|
# check for more than one consecutive space before open brace or
|
||||||
# question mark. Skip lines containing strings since they make it hard
|
# question mark. Skip lines containing strings since they make it hard
|
||||||
# due to artificially getting multiple spaces
|
# due to artificially getting multiple spaces
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
/* This is from the BIND 4.9.4 release, modified to compile by itself */
|
/* This is from the BIND 4.9.4 release, modified to compile by itself */
|
||||||
|
|
||||||
/* Copyright (c) 1996 - 2019 by Internet Software Consortium.
|
/* Copyright (c) 1996 - 2020 by Internet Software Consortium.
|
||||||
*
|
*
|
||||||
* Permission to use, copy, modify, and distribute this software for any
|
* Permission to use, copy, modify, and distribute this software for any
|
||||||
* purpose with or without fee is hereby granted, provided that the above
|
* purpose with or without fee is hereby granted, provided that the above
|
||||||
|
@ -112,7 +112,7 @@ inet_pton4(const char *src, unsigned char *dst)
|
||||||
if(val > 255)
|
if(val > 255)
|
||||||
return (0);
|
return (0);
|
||||||
*tp = (unsigned char)val;
|
*tp = (unsigned char)val;
|
||||||
if(! saw_digit) {
|
if(!saw_digit) {
|
||||||
if(++octets > 4)
|
if(++octets > 4)
|
||||||
return (0);
|
return (0);
|
||||||
saw_digit = 1;
|
saw_digit = 1;
|
||||||
|
|
|
@ -878,7 +878,7 @@ static int dprintf_formatf(
|
||||||
OUTCHAR(' ');
|
OUTCHAR(' ');
|
||||||
for(point = strnil; *point != '\0'; ++point)
|
for(point = strnil; *point != '\0'; ++point)
|
||||||
OUTCHAR(*point);
|
OUTCHAR(*point);
|
||||||
if(! (p->flags & FLAGS_LEFT))
|
if(!(p->flags & FLAGS_LEFT))
|
||||||
while(width-- > 0)
|
while(width-- > 0)
|
||||||
OUTCHAR(' ');
|
OUTCHAR(' ');
|
||||||
}
|
}
|
||||||
|
|
|
@ -5,7 +5,7 @@
|
||||||
* | (__| |_| | _ <| |___
|
* | (__| |_| | _ <| |___
|
||||||
* \___|\___/|_| \_\_____|
|
* \___|\___/|_| \_\_____|
|
||||||
*
|
*
|
||||||
* Copyright (C) 1998 - 2019, Daniel Stenberg, <daniel@haxx.se>, et al.
|
* Copyright (C) 1998 - 2020, Daniel Stenberg, <daniel@haxx.se>, et al.
|
||||||
*
|
*
|
||||||
* This software is licensed as described in the file COPYING, which
|
* This software is licensed as described in the file COPYING, which
|
||||||
* you should have received as part of this distribution. The terms
|
* you should have received as part of this distribution. The terms
|
||||||
|
@ -113,7 +113,7 @@ CURLcode easysrc_addf(struct slist_wc **plist, const char *fmt, ...)
|
||||||
va_start(ap, fmt);
|
va_start(ap, fmt);
|
||||||
bufp = curlx_mvaprintf(fmt, ap);
|
bufp = curlx_mvaprintf(fmt, ap);
|
||||||
va_end(ap);
|
va_end(ap);
|
||||||
if(! bufp) {
|
if(!bufp) {
|
||||||
ret = CURLE_OUT_OF_MEMORY;
|
ret = CURLE_OUT_OF_MEMORY;
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
|
|
|
@ -267,7 +267,7 @@ static char *c_escape(const char *str, curl_off_t len)
|
||||||
strcpy(e, "\\\"");
|
strcpy(e, "\\\"");
|
||||||
e += 2;
|
e += 2;
|
||||||
}
|
}
|
||||||
else if(! isprint(c)) {
|
else if(!isprint(c)) {
|
||||||
msnprintf(e, 5, "\\x%02x", (unsigned)c);
|
msnprintf(e, 5, "\\x%02x", (unsigned)c);
|
||||||
e += 4;
|
e += 4;
|
||||||
}
|
}
|
||||||
|
@ -299,7 +299,7 @@ CURLcode tool_setopt_enum(CURL *curl, struct GlobalConfig *config,
|
||||||
if(nv->value == lval)
|
if(nv->value == lval)
|
||||||
break; /* found it */
|
break; /* found it */
|
||||||
}
|
}
|
||||||
if(! nv->name) {
|
if(!nv->name) {
|
||||||
/* If no definition was found, output an explicit value.
|
/* If no definition was found, output an explicit value.
|
||||||
* This could happen if new values are defined and used
|
* This could happen if new values are defined and used
|
||||||
* but the NameValue list is not updated. */
|
* but the NameValue list is not updated. */
|
||||||
|
|
|
@ -5,7 +5,7 @@
|
||||||
* | (__| |_| | _ <| |___
|
* | (__| |_| | _ <| |___
|
||||||
* \___|\___/|_| \_\_____|
|
* \___|\___/|_| \_\_____|
|
||||||
*
|
*
|
||||||
* Copyright (C) 1998 - 2017, Daniel Stenberg, <daniel@haxx.se>, et al.
|
* Copyright (C) 1998 - 2020, Daniel Stenberg, <daniel@haxx.se>, et al.
|
||||||
*
|
*
|
||||||
* This software is licensed as described in the file COPYING, which
|
* This software is licensed as described in the file COPYING, which
|
||||||
* you should have received as part of this distribution. The terms
|
* you should have received as part of this distribution. The terms
|
||||||
|
@ -71,7 +71,7 @@ int test(char *URL)
|
||||||
return TEST_ERR_MAJOR_BAD;
|
return TEST_ERR_MAJOR_BAD;
|
||||||
}
|
}
|
||||||
|
|
||||||
if(! file_info.st_size) {
|
if(!file_info.st_size) {
|
||||||
fprintf(stderr, "ERROR: file %s has zero size!\n", libtest_arg2);
|
fprintf(stderr, "ERROR: file %s has zero size!\n", libtest_arg2);
|
||||||
fclose(hd_src);
|
fclose(hd_src);
|
||||||
return TEST_ERR_MAJOR_BAD;
|
return TEST_ERR_MAJOR_BAD;
|
||||||
|
|
|
@ -5,7 +5,7 @@
|
||||||
* | (__| |_| | _ <| |___
|
* | (__| |_| | _ <| |___
|
||||||
* \___|\___/|_| \_\_____|
|
* \___|\___/|_| \_\_____|
|
||||||
*
|
*
|
||||||
* Copyright (C) 1998 - 2019, Daniel Stenberg, <daniel@haxx.se>, et al.
|
* Copyright (C) 1998 - 2020, Daniel Stenberg, <daniel@haxx.se>, et al.
|
||||||
*
|
*
|
||||||
* This software is licensed as described in the file COPYING, which
|
* This software is licensed as described in the file COPYING, which
|
||||||
* you should have received as part of this distribution. The terms
|
* you should have received as part of this distribution. The terms
|
||||||
|
@ -63,7 +63,7 @@ int test(char *URL)
|
||||||
return TEST_ERR_MAJOR_BAD;
|
return TEST_ERR_MAJOR_BAD;
|
||||||
}
|
}
|
||||||
|
|
||||||
if(! file_info.st_size) {
|
if(!file_info.st_size) {
|
||||||
fprintf(stderr, "ERROR: file %s has zero size!\n", libtest_arg2);
|
fprintf(stderr, "ERROR: file %s has zero size!\n", libtest_arg2);
|
||||||
fclose(hd_src);
|
fclose(hd_src);
|
||||||
return TEST_ERR_MAJOR_BAD;
|
return TEST_ERR_MAJOR_BAD;
|
||||||
|
|
Загрузка…
Ссылка в новой задаче