aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarcoFalke <[email protected]>2018-05-02 15:12:18 +0200
committerWladimir J. van der Laan <[email protected]>2018-05-02 15:14:37 +0200
commit4b75dcf0ec7beecc9a4638305d1beed9477ba06e (patch)
treee06dc43a0c8cc0c57343e5dc21474492d0f6640b
parentAdd missing newlines to LogPrint debug logging (diff)
downloaddiscoin-4b75dcf0ec7beecc9a4638305d1beed9477ba06e.tar.xz
discoin-4b75dcf0ec7beecc9a4638305d1beed9477ba06e.zip
devtools: Make linter check LogPrint calls
-rwxr-xr-xcontrib/devtools/lint-logs.sh5
1 files changed, 3 insertions, 2 deletions
diff --git a/contrib/devtools/lint-logs.sh b/contrib/devtools/lint-logs.sh
index 3bb54359a..35be13ec1 100755
--- a/contrib/devtools/lint-logs.sh
+++ b/contrib/devtools/lint-logs.sh
@@ -13,12 +13,13 @@
# ignored
-UNTERMINATED_LOGS=$(git grep "LogPrintf(" -- "*.cpp" | \
+UNTERMINATED_LOGS=$(git grep --extended-regexp "LogPrintf?\(" -- "*.cpp" | \
grep -v '\\n"' | \
grep -v "/\* Continued \*/" | \
+ grep -v "LogPrint()" | \
grep -v "LogPrintf()")
if [[ ${UNTERMINATED_LOGS} != "" ]]; then
- echo "All calls to LogPrintf() should be terminated with \\n"
+ echo "All calls to LogPrintf() and LogPrint() should be terminated with \\n"
echo
echo "${UNTERMINATED_LOGS}"
exit 1