From 3b45898fa6cb308f37c5263824b68a3626792d97 Mon Sep 17 00:00:00 2001 From: Chris Lamb Date: Fri, 30 Oct 2009 13:15:57 +0000 Subject: [PATCH] Don't shadow 'dir' builtin in daklib.utils.get_changes_files Signed-off-by: Chris Lamb --- daklib/utils.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/daklib/utils.py b/daklib/utils.py index 45d1895d..80e8d68f 100755 --- a/daklib/utils.py +++ b/daklib/utils.py @@ -1487,7 +1487,7 @@ def is_email_alias(email): ################################################################################ -def get_changes_files(dir): +def get_changes_files(from_dir): """ Takes a directory and lists all .changes files in it (as well as chdir'ing to the directory; this is due to broken behaviour on the part of p-u/p-a @@ -1497,10 +1497,10 @@ def get_changes_files(dir): """ try: # Much of the rest of p-u/p-a depends on being in the right place - os.chdir(dir) - changes_files = [x for x in os.listdir(dir) if x.endswith('.changes')] + os.chdir(from_dir) + changes_files = [x for x in os.listdir(from_dir) if x.endswith('.changes')] except OSError, e: - fubar("Failed to read list from directory %s (%s)" % (dir, e)) + fubar("Failed to read list from directory %s (%s)" % (from_dir, e)) return changes_files -- 2.39.5