]> git.ipfire.org Git - thirdparty/bind9.git/commit
Add semantic patch to explicitly cast chars to unsigned for ctype.h
authorOndřej Surý <ondrej@isc.org>
Wed, 20 Sep 2023 15:23:28 +0000 (17:23 +0200)
committerOndřej Surý <ondrej@isc.org>
Fri, 22 Sep 2023 15:01:18 +0000 (17:01 +0200)
commitd9b8412f0843d7cfc71ec6877381a49c19c30a90
treebc3667a28e0e57f5714dae242c1e3f7711b4e33e
parent7ff22f5961cc1361dade5a7697d9be6ceaa5a146
Add semantic patch to explicitly cast chars to unsigned for ctype.h

Add a semantic patch to catch all the places where we pass 'char' to the
<ctype.h> family of functions (isalpha() and friends, toupper(),
tolower()).  While it generally works because the way how these
functions are constructed in the libc, it's safer to do the explicit
cast.

(cherry picked from commit 5ec65ab5d082616716c94ebff94636daf1f789ac)
cocci/ctype.spatch [new file with mode: 0644]