summaryrefslogtreecommitdiffstats
path: root/Lib/fnmatch.py
diff options
context:
space:
mode:
authorGregory P. Smith <greg@mad-scientist.com>2009-08-16 18:52:58 (GMT)
committerGregory P. Smith <greg@mad-scientist.com>2009-08-16 18:52:58 (GMT)
commitb98d6b2cbcba1344609a60c7c0fb9f595d19023b (patch)
treeda262aa1f7023cbf321b115fde7dd3d8f2693a89 /Lib/fnmatch.py
parent1ce2d5305a0494aa6ce476892e91b117ed40ce7d (diff)
downloadcpython-b98d6b2cbcba1344609a60c7c0fb9f595d19023b.zip
cpython-b98d6b2cbcba1344609a60c7c0fb9f595d19023b.tar.gz
cpython-b98d6b2cbcba1344609a60c7c0fb9f595d19023b.tar.bz2
Issue 6665: Fix fnmatch to properly match filenames with newlines in them.
Diffstat (limited to 'Lib/fnmatch.py')
-rw-r--r--Lib/fnmatch.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/Lib/fnmatch.py b/Lib/fnmatch.py
index 3bf2463..4c149eb 100644
--- a/Lib/fnmatch.py
+++ b/Lib/fnmatch.py
@@ -104,4 +104,4 @@ def translate(pat):
res = '%s[%s]' % (res, stuff)
else:
res = res + re.escape(c)
- return res + "$"
+ return res + '\Z(?ms)'