svn commit: r242405 - user/crees/rclint

Chris Rees crees at FreeBSD.org
Wed Oct 31 20:51:42 UTC 2012


Author: crees (ports committer)
Date: Wed Oct 31 20:51:41 2012
New Revision: 242405
URL: http://svn.freebsd.org/changeset/base/242405

Log:
  Be more relaxed about quoting by being observant of POSIX, rather than our
  sh's behaviour
  
  Submitted by:	jilles

Modified:
  user/crees/rclint/rclint.py

Modified: user/crees/rclint/rclint.py
==============================================================================
--- user/crees/rclint/rclint.py	Wed Oct 31 19:17:55 2012	(r242404)
+++ user/crees/rclint/rclint.py	Wed Oct 31 20:51:41 2012	(r242405)
@@ -109,11 +109,10 @@ class Statement:
 
     def pointless_quoted(self):
         if self.quoted():
-            if self.type == 'shorthand':
-                return True
-            elif ' ' not in self.value and '\t' not in self.value:
-                return True
-        return False
+            for char in self.value:
+                if char in ' \t|&;<>()$`\\\"\'':
+                    return False
+        return True
 
 class Variable(Statement):
     def __init__(self, lines, number):


More information about the svn-src-user mailing list