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

[dak/master] dont know python? come, join the ftpteam and write code. works for me.



Signed-off-by: Joerg Jaspert <joerg@debian.org>
---
 daklib/archive.py |    2 +-
 daklib/utils.py   |    4 ++--
 2 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/daklib/archive.py b/daklib/archive.py
index 6562c67..78df632 100644
--- a/daklib/archive.py
+++ b/daklib/archive.py
@@ -624,7 +624,7 @@ class ArchiveUpload(object):
         session = self.transaction.session
 
         self.directory = utils.temp_dirname(parent=cnf.get('Dir::TempPath'),
-                                            mode=0o2750, group=cnf.unprivgroup)[1]
+                                            mode=0o2750, group=cnf.unprivgroup)
         with FilesystemTransaction() as fs:
             src = os.path.join(self.original_directory, self.original_changes.filename)
             dst = os.path.join(self.directory, self.original_changes.filename)
diff --git a/daklib/utils.py b/daklib/utils.py
index 25d768d..8a16035 100755
--- a/daklib/utils.py
+++ b/daklib/utils.py
@@ -1497,12 +1497,12 @@ def temp_dirname(parent=None, prefix="dak", suffix="", mode=None, group=None):
 
     """
 
-    (tfd, tfname) = tempfile.mkdtemp(suffix, prefix, parent)
+    tfname = tempfile.mkdtemp(suffix, prefix, parent)
     if mode:
         os.chmod(tfname, mode)
     if group:
         os.chown(tfname, -1, group)
-    return (tfd, tfname)
+    return tfname
 
 ################################################################################
 
-- 
1.7.2.5


Reply to: