summaryrefslogtreecommitdiff
path: root/usr.sbin
diff options
context:
space:
mode:
authorMarc Espie <espie@cvs.openbsd.org>2014-08-10 10:03:47 +0000
committerMarc Espie <espie@cvs.openbsd.org>2014-08-10 10:03:47 +0000
commit328449462693153d556e636c902e210aaa3dd8d1 (patch)
tree250e305abb56c5147946fdb09d802163d067cbbf /usr.sbin
parentadd3135f3ad44210d6dc51a85af9a9872dd52fcc (diff)
Ouch... fuck cvs
Diffstat (limited to 'usr.sbin')
-rw-r--r--usr.sbin/pkg_add/OpenBSD/Ustar.pm10
1 files changed, 6 insertions, 4 deletions
diff --git a/usr.sbin/pkg_add/OpenBSD/Ustar.pm b/usr.sbin/pkg_add/OpenBSD/Ustar.pm
index a0ab18c070b..bc8df81cfd9 100644
--- a/usr.sbin/pkg_add/OpenBSD/Ustar.pm
+++ b/usr.sbin/pkg_add/OpenBSD/Ustar.pm
@@ -1,5 +1,5 @@
# ex:ts=8 sw=4:
-# $OpenBSD: Ustar.pm,v 1.81 2014/08/10 10:01:03 espie Exp $
+# $OpenBSD: Ustar.pm,v 1.82 2014/08/10 10:03:46 espie Exp $
#
# Copyright (c) 2002-2014 Marc Espie <espie@openbsd.org>
#
@@ -313,7 +313,7 @@ sub pack_header
sprintf("%07o", $entry->{uid}),
sprintf("%07o", $entry->{gid}),
sprintf("%011o", $size),
- sprintf("%011o", $entry->{mtime}),
+ sprintf("%011o", $entry->{mtime} // 0),
$cksum,
$type,
$linkname,
@@ -488,8 +488,10 @@ package OpenBSD::Ustar::Object;
sub recheck_owner
{
my $entry = shift;
- $entry->{uid} //= $OpenBSD: Ustar.pm,v 1.81 2014/08/10 10:01:03 espie Exp $entry->{uname});
- $entry->{gid} //= $OpenBSD: Ustar.pm,v 1.81 2014/08/10 10:01:03 espie Exp $entry->{gname});
+ $entry->{uid} //= $OpenBSD::Ustar::uidcache
+ ->lookup($entry->{uname});
+ $entry->{gid} //= $OpenBSD::Ustar::gidcache
+ ->lookup($entry->{gname});
}
sub fatal