summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rwxr-xr-xdraklive-install5
1 files changed, 4 insertions, 1 deletions
diff --git a/draklive-install b/draklive-install
index 2206b24..7ae8dbc 100755
--- a/draklive-install
+++ b/draklive-install
@@ -9,6 +9,7 @@ use fs::partitioning;
use fs::partitioning_wizard;
use MDK::Common;
use common;
+use feature qw(state);
push @::textdomains, 'draklive-install';
@@ -154,8 +155,10 @@ sub build_copy_command {
sub get_total_size {
my ($in, $source) = @_;
+ state $total;
+ return $total if $total;
my $_wait = $in->wait_message('', N("Computing total size"));
- first(split(/\s+/, `du -sbx $source 2>/dev/null`));
+ $total = first(split(/\s+/, `du -sbx $source 2>/dev/null`));
}
sub copy_root {