From e571c7b55a0fb16fa23c27c13346db30edf2f444 Mon Sep 17 00:00:00 2001 From: Joerg Jaspert Date: Sun, 16 Sep 2012 18:16:35 +0200 Subject: [PATCH] dont know python? come, join the ftpteam and write code. works for me. Signed-off-by: Joerg Jaspert --- 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 6562c67c..78df632e 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 25d768d1..8a160356 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 ################################################################################ -- 2.39.5