]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
Fix build error.
authorAlexandre Vassalotti <alexandre@peadrop.com>
Sun, 27 Jan 2008 16:16:19 +0000 (16:16 +0000)
committerAlexandre Vassalotti <alexandre@peadrop.com>
Sun, 27 Jan 2008 16:16:19 +0000 (16:16 +0000)
Use a list comprehension instead of filter(), since filter() needs the
itertools module which isn't available at build time.

Lib/glob.py

index 0e2bc1e7342ad2920d4decec5a878a8b91a80b87..cd6c3024ca4202fa2b085f94b9cae7683b3b2854 100644 (file)
@@ -57,7 +57,7 @@ def glob1(dirname, pattern):
     except os.error:
         return []
     if pattern[0] != '.':
-        names = filter(lambda x: x[0] != '.', names)
+        names = [x for x in names if x[0] != '.']
     return fnmatch.filter(names, pattern)
 
 def glob0(dirname, basename):