summaryrefslogtreecommitdiff
path: root/usr.sbin/pkg_add/OpenBSD/Add.pm
diff options
context:
space:
mode:
Diffstat (limited to 'usr.sbin/pkg_add/OpenBSD/Add.pm')
-rw-r--r--usr.sbin/pkg_add/OpenBSD/Add.pm6
1 files changed, 3 insertions, 3 deletions
diff --git a/usr.sbin/pkg_add/OpenBSD/Add.pm b/usr.sbin/pkg_add/OpenBSD/Add.pm
index b6b027b8d1c..a5abadd108a 100644
--- a/usr.sbin/pkg_add/OpenBSD/Add.pm
+++ b/usr.sbin/pkg_add/OpenBSD/Add.pm
@@ -1,5 +1,5 @@
# ex:ts=8 sw=4:
-# $OpenBSD: Add.pm,v 1.14 2004/11/11 12:29:58 espie Exp $
+# $OpenBSD: Add.pm,v 1.15 2004/11/12 21:52:01 espie Exp $
#
# Copyright (c) 2003-2004 Marc Espie <espie@openbsd.org>
#
@@ -245,15 +245,15 @@ sub install
my $destdir = $state->{destdir};
if ($state->{replacing}) {
-
return if $state->{not};
+ File::Path::mkpath(dirname($destdir.$fullname));
if (defined $self->{link}) {
link($destdir.$self->{link}, $destdir.$fullname);
} elsif (defined $self->{symlink}) {
symlink($self->{symlink}, $destdir.$fullname);
} else {
rename($self->{tempname}, $destdir.$fullname) or
- Fatal "Can't move file to $fullname: $!";
+ Fatal "Can't move ", $self->{tempname}, " to $fullname: $!";
print "moving ", $self->{tempname}, " -> $destdir$fullname\n" if $state->{very_verbose};
undef $self->{tempname};
}