]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
#9723: refactor regex.
authorEzio Melotti <ezio.melotti@gmail.com>
Tue, 16 Aug 2011 16:03:41 +0000 (19:03 +0300)
committerEzio Melotti <ezio.melotti@gmail.com>
Tue, 16 Aug 2011 16:03:41 +0000 (19:03 +0300)
Lib/shlex.py

index 92c49c360842db6250cf7854bf07ca8aa7f47dfa..69f3b456af103cc9067c30be5075d0fdf1e7001c 100644 (file)
@@ -276,7 +276,7 @@ def split(s, comments=False, posix=True):
     return list(lex)
 
 
-_find_unsafe = re.compile(r'[^\w@%\-\+=:,\./]', re.ASCII).search
+_find_unsafe = re.compile(r'[^\w@%+=:,./-]', re.ASCII).search
 
 def quote(s):
     """Return a shell-escaped version of the string *s*."""