aboutsummaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorMarcoFalke <falke.marco@gmail.com>2021-11-12 11:19:44 +0100
committerMarcoFalke <falke.marco@gmail.com>2021-11-16 09:56:45 +0100
commitfa44237d76b66b6664870c3927b65a0ef89022e4 (patch)
tree2f60626fda466410facd55c259ff70ddeaf366db /test
parentad09c287cb7033a28f8d0a002c1ca4f194c12f11 (diff)
doc: Fix typos in endif header comments
Diffstat (limited to 'test')
-rwxr-xr-xtest/lint/lint-include-guards.sh2
1 files changed, 1 insertions, 1 deletions
diff --git a/test/lint/lint-include-guards.sh b/test/lint/lint-include-guards.sh
index ac2177bbe3..23f53f027e 100755
--- a/test/lint/lint-include-guards.sh
+++ b/test/lint/lint-include-guards.sh
@@ -17,7 +17,7 @@ for HEADER_FILE in $(git ls-files -- "*.h" | grep -vE "^${REGEXP_EXCLUDE_FILES_W
do
HEADER_ID_BASE=$(cut -f2- -d/ <<< "${HEADER_FILE}" | sed "s/\.h$//g" | tr / _ | tr - _ | tr "[:lower:]" "[:upper:]")
HEADER_ID="${HEADER_ID_PREFIX}${HEADER_ID_BASE}${HEADER_ID_SUFFIX}"
- if [[ $(grep -cE "^#(ifndef|define) ${HEADER_ID}" "${HEADER_FILE}") != 2 ]]; then
+ if [[ $(grep --count --extended-regexp "^#(ifndef|define|endif //) ${HEADER_ID}" "${HEADER_FILE}") != 3 ]]; then
echo "${HEADER_FILE} seems to be missing the expected include guard:"
echo " #ifndef ${HEADER_ID}"
echo " #define ${HEADER_ID}"