[Libreoffice-commits] core.git: solenv/bin

Katarina Behrens Katarina.Behrens at cib.de
Wed Dec 14 10:45:50 UTC 2016


 solenv/bin/packimages.pl |    5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

New commits:
commit d2c2388c43e8430c18d26af2a5d26ab58b629675
Author: Katarina Behrens <Katarina.Behrens at cib.de>
Date:   Tue Dec 13 11:38:00 2016 +0100

    Don't leak .png files into tmp
    
    Temp directory created by copy_images (which contains copies of .png files
    from any given icon-themes folder) was left behind. Happening at least since
    commit 4e3dc8c141c2efd037c1f214b5edff071812b6a8
    
    Date:   Fri Jun 3 17:09:14 2016 +0200
    
        remove use of Archive::Zip
    
    With packimages.pl now used to package also screenshot images (in
    multiple languages), tmp fills up quickly. This is fatal on Windows
    
    Change-Id: Ie35c33277a80ed9085815f30b846bb97a365afb1
    Reviewed-on: https://gerrit.libreoffice.org/31947
    Reviewed-by: Katarina Behrens <Katarina.Behrens at cib.de>
    Tested-by: Katarina Behrens <Katarina.Behrens at cib.de>

diff --git a/solenv/bin/packimages.pl b/solenv/bin/packimages.pl
index fb141c0..16f39f4 100755
--- a/solenv/bin/packimages.pl
+++ b/solenv/bin/packimages.pl
@@ -28,7 +28,7 @@ use Getopt::Long;
 use File::Find;
 use File::Basename;
 use File::Copy qw(copy);
-use File::Path qw(make_path);
+use File::Path qw(make_path rmtree);
 require File::Temp;
 use File::Temp qw(tempdir);
 
@@ -99,6 +99,9 @@ if ( $do_rebuild == 1 ) {
     create_zip_archive($zip_hash_ref, \%links, $tmpdir);
     replace_file($tmp_out_file, $out_file);
     print_message("packing  $out_file finished.") if $verbose;
+
+    rmtree($tmpdir);
+    print_error("failed to delete $tmpdir") if -e $tmpdir;
 } else {
     print_message("$out_file up to date. nothing to do.") if $verbose;
 }


More information about the Libreoffice-commits mailing list