diff options
author | Marc Espie <espie@cvs.openbsd.org> | 2023-05-16 16:45:05 +0000 |
---|---|---|
committer | Marc Espie <espie@cvs.openbsd.org> | 2023-05-16 16:45:05 +0000 |
commit | 1e9601b85c5998775a147a4e598112094d3b0e88 (patch) | |
tree | 3506ec17c90404f3b0db9bcca74a051240f2413a /usr.sbin/pkg_add/OpenBSD | |
parent | e9b0753af749a4a3b9e0813e51b958b7d9641b9a (diff) |
clean visible interface a bit: Ustar does not use errsay (but ArcCheck does)
and having a forwarder for system for ONE use is a bit much !
Diffstat (limited to 'usr.sbin/pkg_add/OpenBSD')
-rw-r--r-- | usr.sbin/pkg_add/OpenBSD/ArcCheck.pm | 8 | ||||
-rw-r--r-- | usr.sbin/pkg_add/OpenBSD/Ustar.pm | 15 |
2 files changed, 9 insertions, 14 deletions
diff --git a/usr.sbin/pkg_add/OpenBSD/ArcCheck.pm b/usr.sbin/pkg_add/OpenBSD/ArcCheck.pm index b4195cd3ca8..d267af66af2 100644 --- a/usr.sbin/pkg_add/OpenBSD/ArcCheck.pm +++ b/usr.sbin/pkg_add/OpenBSD/ArcCheck.pm @@ -1,5 +1,5 @@ # ex:ts=8 sw=4: -# $OpenBSD: ArcCheck.pm,v 1.38 2023/05/16 14:33:04 espie Exp $ +# $OpenBSD: ArcCheck.pm,v 1.39 2023/05/16 16:45:04 espie Exp $ # # Copyright (c) 2005-2006 Marc Espie <espie@openbsd.org> # @@ -53,6 +53,12 @@ sub check_linkname return $c eq $linkname; } +sub errsay +{ + my ($self, @args) = @_; + $self->{archive}{state}->errsay(@args); +} + sub validate_meta { my ($o, $item) = @_; diff --git a/usr.sbin/pkg_add/OpenBSD/Ustar.pm b/usr.sbin/pkg_add/OpenBSD/Ustar.pm index 38735744561..253c2b3ddb6 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.92 2023/05/16 14:30:12 espie Exp $ +# $OpenBSD: Ustar.pm,v 1.93 2023/05/16 16:45:04 espie Exp $ # # Copyright (c) 2002-2014 Marc Espie <espie@openbsd.org> # @@ -515,17 +515,6 @@ sub fatal $self->{archive}->fatal(@args); } -sub system -{ - my ($self, @args) = @_; - $self->{archive}{state}->system(@args); -} - -sub errsay -{ - my ($self, @args) = @_; - $self->{archive}{state}->errsay(@args); -} sub left_todo { my ($self, $toread) = @_; @@ -737,7 +726,7 @@ sub create { my $self = shift; $self->make_basedir; - $self->system(OpenBSD::Paths->mknod, + $self->{archive}{state}->system(OpenBSD::Paths->mknod, '-m', $self->{mode}, '--', $self->fullname, $self->devicetype, $self->{major}, $self->{minor}); $self->set_modes; |