aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rwxr-xr-xicevault8
1 files changed, 4 insertions, 4 deletions
diff --git a/icevault b/icevault
index c0dd55b..9962f21 100755
--- a/icevault
+++ b/icevault
@@ -304,9 +304,9 @@ sub saveIdentityFile($$) {
error "C<%s> exited with value %d", $CONFIG{gpg}, ($? >> 8) if $? and $? != -1;
$outfh->close;
- my $parent_dir = $filename =~ s/\/[^\/]+$//r;
- File::Path::make_path $parent_dir unless -d $parent_dir; # create parent directories recursively
- File::Copy::move $outfh->filename, $filename or error "Can't move C<%s>: %s", $outfh->filename, $!;
+ my $parent_dir = $file =~ s/\/[^\/]+$//r;
+ File::Path::make_path($parent_dir) unless -d $parent_dir; # create parent directories recursively
+ File::Copy::move($outfh->filename, $file) or error "Can't move C<%s>: %s", $outfh->filename, $!;
# TODO: git add $filename; git commit
}
@@ -768,7 +768,7 @@ elsif ($command eq 'edit') {
error "C<%s> exited with value %d", $CONFIG{gpg}, ($? >> 8) if $? and $? != -1;
$outfh->close;
- File::Copy::move $outfh->filename, $filename or error "Can't move C<%s>: %s", $outfh->filename, $!;
+ File::Copy::move($outfh->filename, $file) or error "Can't move C<%s>: %s", $outfh->filename, $!;
}
close $NULL;