mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2024-08-27 02:51:16 +00:00
sytnax-check: add a check for risky ctype macro use
* Makefile.maint (sc_risky_ctype_macros): New rule.
This commit is contained in:
parent
b8111adf35
commit
eb046f9d59
@ -1,5 +1,8 @@
|
|||||||
Fri May 9 10:01:34 EST 2008 Jim Meyering <meyering@redhat.com>
|
Fri May 9 10:01:34 EST 2008 Jim Meyering <meyering@redhat.com>
|
||||||
|
|
||||||
|
sytnax-check: add a check for risky ctype macro use
|
||||||
|
* Makefile.maint (sc_risky_ctype_macros): New rule.
|
||||||
|
|
||||||
avoid one more ctype vs. sign-extension problem
|
avoid one more ctype vs. sign-extension problem
|
||||||
* src/util.c (TOLOWER): Also convert tolower argument.
|
* src/util.c (TOLOWER): Also convert tolower argument.
|
||||||
|
|
||||||
|
@ -302,6 +302,15 @@ sc_TAB_in_indentation:
|
|||||||
{ echo '$(ME): found TAB(s) use for indentation; use spaces' \
|
{ echo '$(ME): found TAB(s) use for indentation; use spaces' \
|
||||||
1>&2; exit 1; } || :
|
1>&2; exit 1; } || :
|
||||||
|
|
||||||
|
ctype_re = isalnum|isalpha|isascii|isblank|iscntrl|isdigit|isgraph|islower\
|
||||||
|
|isprint|ispunct|isspace|isupper|isxdigit|tolower|toupper
|
||||||
|
|
||||||
|
sc_risky_ctype_macros:
|
||||||
|
@grep -E '\b($(ctype_re)) *\(' /dev/null \
|
||||||
|
$$($(VC_LIST_EXCEPT)) | grep -v to_uchar && \
|
||||||
|
{ echo '$(ME): found ctype macro use without to_uchar' \
|
||||||
|
1>&2; exit 1; } || :
|
||||||
|
|
||||||
# Match lines like the following, but where there is only one space
|
# Match lines like the following, but where there is only one space
|
||||||
# between the options and the description:
|
# between the options and the description:
|
||||||
# -D, --all-repeated[=delimit-method] print all duplicate lines\n
|
# -D, --all-repeated[=delimit-method] print all duplicate lines\n
|
||||||
|
Loading…
Reference in New Issue
Block a user