changeset 29520:57106f357cd1

check-code: enforce (glob) on output lines containing 127.0.0.1
author Augie Fackler <raf@durin42.com>
date Sat, 09 Jul 2016 23:04:03 -0400
parents fe7158fced4b
children 83147ff53112
files contrib/check-code.py
diffstat 1 files changed, 4 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/contrib/check-code.py	Sat Jul 09 23:03:45 2016 -0400
+++ b/contrib/check-code.py	Sat Jul 09 23:04:03 2016 -0400
@@ -189,6 +189,8 @@
     (r'^  .*: largefile \S+ not available from file:.*/.*[^)]$', winglobmsg),
     (r'^  .*file://\$TESTTMP',
      'write "file:/*/$TESTTMP" + (glob) to match on windows too'),
+    (r'^  [^$>].*27\.0\.0\.1.*[^)]$',
+     'use (glob) to match localhost IP on hosts without 127.0.0.1 too'),
     (r'^  (cat|find): .*: No such file or directory',
      'use test -f to test for file existence'),
     (r'^  diff -[^ -]*p',
@@ -207,8 +209,8 @@
   ],
   # warnings
   [
-    (r'^  [^*?/\n]* \(glob\)$',
-     "glob match with no glob character (?*/)"),
+    (r'^  (?!.*127\.0\.0\.1)[^*?/\n]* \(glob\)$',
+     "glob match with no glob string (?, *, /, and 127.0.0.1)"),
   ]
 ]