Skip to content
Permalink
Browse files

cppcheck.sh: turn 'redundantCondition' warnings as errors

  • Loading branch information
rouault authored and nyalldawson committed Jun 13, 2020
1 parent 6480810 commit 037409f2e3d5a708e78b2addb11a03a9c74a6fad
Showing with 2 additions and 2 deletions.
  1. +2 −2 scripts/cppcheck.sh
@@ -52,12 +52,12 @@ mv ${LOG_FILE}.tmp ${LOG_FILE}
for category in "style" "performance" "portability"; do
if grep "${category}," ${LOG_FILE} >/dev/null; then
echo "INFO: Issues in '${category}' category found, but not considered as making script to fail:"
grep "${category}," ${LOG_FILE} | grep -v -e "clarifyCalculation," -e "duplicateExpressionTernary,"
grep "${category}," ${LOG_FILE} | grep -v -e "clarifyCalculation," -e "duplicateExpressionTernary," -e "redundantCondition,"
echo ""
fi
done

for category in "error" "warning" "clarifyCalculation" "duplicateExpressionTernary"; do
for category in "error" "warning" "clarifyCalculation" "duplicateExpressionTernary" "redundantCondition"; do
if grep "${category}," ${LOG_FILE} >/dev/null; then
echo "ERROR: Issues in '${category}' category found:"
grep "${category}," ${LOG_FILE}

0 comments on commit 037409f

Please sign in to comment.
You can’t perform that action at this time.