[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

[dak/master 1/3] Replace base_filename with os.path.basename



base_filename is not defined before, replace it with a function
to avoid generating a NameError exception

Signed-off-by: Luca Falavigna <dktrkranz@debian.org>
---
 daklib/queue.py |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/daklib/queue.py b/daklib/queue.py
index 58fdf7f..6accba0 100755
--- a/daklib/queue.py
+++ b/daklib/queue.py
@@ -454,7 +454,7 @@ class Upload(object):
 
         # Check the .changes is non-empty
         if not self.pkg.files:
-            self.rejects.append("%s: nothing to do (Files field is empty)." % (base_filename))
+            self.rejects.append("%s: nothing to do (Files field is empty)." % (os.path.basename(self.pkg.changes_file)))
             return False
 
         # Changes was syntactically valid even if we'll reject
-- 
1.7.1



Reply to: