mirror of
https://github.com/fspc/gbootroot.git
synced 2025-02-24 09:23:23 -05:00
This prevents the app. from not locking when really large files are compressed,
it locks a little between large chunks, but a lot better than before .. also there is now a little verbosity to tell when the process is over.
This commit is contained in:
parent
82ced90590
commit
823f521ffe
@ -1,6 +1,6 @@
|
|||||||
#!/usr/bin/perl -w
|
#!/usr/bin/perl -w
|
||||||
|
|
||||||
###########################################################################
|
##############################################################################
|
||||||
##
|
##
|
||||||
## BootRoot.pm
|
## BootRoot.pm
|
||||||
## Copyright (C) 2000, 2001 by Jonathan Rosenbaum
|
## Copyright (C) 2000, 2001 by Jonathan Rosenbaum
|
||||||
@ -1507,10 +1507,26 @@ sub accept_button {
|
|||||||
info(0, "Already bzip2 compressed.\n");
|
info(0, "Already bzip2 compressed.\n");
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
|
my $command_line =
|
||||||
|
"$compress -c9 $tmp/$entry_advanced[4]|";
|
||||||
|
info(0,"Compressing $entry_advanced[4] with $compress\n");
|
||||||
|
open (PLACE, ">$tmp/$entry_advanced[4].gz");
|
||||||
|
open (COMP,"$command_line");
|
||||||
|
while (<COMP>) {
|
||||||
|
print PLACE $_;
|
||||||
|
while (Gtk->events_pending)
|
||||||
|
{ Gtk->main_iteration; }
|
||||||
|
}
|
||||||
|
close(COMP);
|
||||||
|
close(PLACE);
|
||||||
|
info(0,"Done compressing $entry_advanced[4] with $compress\n");
|
||||||
|
=pod
|
||||||
system
|
system
|
||||||
"$compress -c9 $tmp/$entry_advanced[4] > $tmp/$entry_advanced[4].gz";
|
"$compress -c9 $tmp/$entry_advanced[4] > $tmp/$entry_advanced[4].gz";
|
||||||
|
=cut
|
||||||
$entry_advanced[4] = "$entry_advanced[4].gz";
|
$entry_advanced[4] = "$entry_advanced[4].gz";
|
||||||
$entry3->set_text("$tmp/$entry_advanced[4]");
|
$entry3->set_text("$tmp/$entry_advanced[4]");
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
close(F);
|
close(F);
|
||||||
@ -1537,10 +1553,28 @@ sub accept_button {
|
|||||||
info(0, "Already bzip2 compressed.\n");
|
info(0, "Already bzip2 compressed.\n");
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
|
|
||||||
|
my $command_line =
|
||||||
|
"$compress -c $tmp/$entry_advanced[4]|";
|
||||||
|
info(0,"Compressing $entry_advanced[4] with $compress\n");
|
||||||
|
open (PLACE, ">$tmp/$entry_advanced[4].bz2");
|
||||||
|
open (COMP,"$command_line");
|
||||||
|
while (<COMP>) {
|
||||||
|
print PLACE $_;
|
||||||
|
while (Gtk->events_pending)
|
||||||
|
{ Gtk->main_iteration; }
|
||||||
|
}
|
||||||
|
close(COMP);
|
||||||
|
close(PLACE);
|
||||||
|
info(0,"Done compressing $entry_advanced[4] with $compress\n");
|
||||||
|
|
||||||
|
=pod
|
||||||
system
|
system
|
||||||
"$compress -c $tmp/$entry_advanced[4] > $tmp/$entry_advanced[4].bz2";
|
"$compress -c $tmp/$entry_advanced[4] > $tmp/$entry_advanced[4].bz2";
|
||||||
|
=cut
|
||||||
$entry_advanced[4] = "$entry_advanced[4].bz2";
|
$entry_advanced[4] = "$entry_advanced[4].bz2";
|
||||||
$entry3->set_text("$tmp/$entry_advanced[4]");
|
$entry3->set_text("$tmp/$entry_advanced[4]");
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
close(F);
|
close(F);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user