Bug 12081: make tmpl_process3.pl delete ts temp files

This patch enable deletion of temp files used by
tmpl_process3.pl.
Just removed coments on existing code

To test:
1. Do a count of files on /tmp ( ls /tmp | wc -l )
2. Update preferred language
3. Count again, new files on /tmp
4. Apply the patch
5. Update again, check, no new files

Signed-off-by: Mark Tompsett <mtompset@hotmail.com>

NOTE: I watched what temp files were actually in /tmp to make
      sure other processes didn't magically increase/decrease
      the number.
          $ perl translate update {lang code}
      generated 10 temporary files for me (2x5 po files). After
      removing those ten files, and applying the patch, no
      other files were generated.

Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
These lines has been commented by commit
a399dcefad without any apparent good
reason.

Signed-off-by: Galen Charlton <gmc@esilibrary.com>
This commit is contained in:
Bernardo Gonzalez Kriegel 2014-04-14 19:35:35 -03:00 committed by Galen Charlton
parent b324e893e8
commit de81d7abe4

View file

@ -353,8 +353,8 @@ if ($action eq 'create') {
error_normal "Text extraction failed: $xgettext: $!\n", undef;
error_additional "Will not run msgmerge\n", undef;
}
# unlink $tmpfile1 || warn_normal "$tmpfile1: unlink failed: $!\n", undef;
# unlink $tmpfile2 || warn_normal "$tmpfile2: unlink failed: $!\n", undef;
unlink $tmpfile1 || warn_normal "$tmpfile1: unlink failed: $!\n", undef;
unlink $tmpfile2 || warn_normal "$tmpfile2: unlink failed: $!\n", undef;
} elsif ($action eq 'update') {
my($tmph1, $tmpfile1) = tmpnam();
@ -386,8 +386,8 @@ if ($action eq 'create') {
error_normal "Text extraction failed: $xgettext: $!\n", undef;
error_additional "Will not run msgmerge\n", undef;
}
# unlink $tmpfile1 || warn_normal "$tmpfile1: unlink failed: $!\n", undef;
# unlink $tmpfile2 || warn_normal "$tmpfile2: unlink failed: $!\n", undef;
unlink $tmpfile1 || warn_normal "$tmpfile1: unlink failed: $!\n", undef;
unlink $tmpfile2 || warn_normal "$tmpfile2: unlink failed: $!\n", undef;
} elsif ($action eq 'install') {
if(!defined($out_dir)) {