[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

[tor-commits] [rbm/master] Bug 40026: Make sure tmp dir are removed after build_run finished



commit 2c0e72317ef71ba1be9aa8f0d3cadec9a60b626f
Author: Nicolas Vigier <boklm@xxxxxxxxxxxxxx>
Date:   Fri Apr 23 19:19:58 2021 +0200

    Bug 40026: Make sure tmp dir are removed after build_run finished
---
 lib/RBM.pm | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/lib/RBM.pm b/lib/RBM.pm
index 57b5dde..beaa690 100644
--- a/lib/RBM.pm
+++ b/lib/RBM.pm
@@ -1029,8 +1029,9 @@ sub build_run {
     valid_project($project);
     $options = { %$options, build_id => Data::UUID->new->create_str };
     my $old_cwd = getcwd;
-    my $srcdir = File::Temp->newdir(get_tmp_dir($project, $options)
+    my $tmpdir = File::Temp->newdir(get_tmp_dir($project, $options)
                                 . '/rbm-XXXXX');
+    my $srcdir = $tmpdir->dirname;
     my @cfiles;
     my $tarfile = maketar($project, $options, $srcdir);
     push @cfiles, $tarfile if $tarfile;

_______________________________________________
tor-commits mailing list
tor-commits@xxxxxxxxxxxxxxxxxxxx
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-commits