From: espie Date: Wed, 14 Jun 2023 09:59:09 +0000 (+0000) Subject: GC remnants of pipe support, long gone. X-Git-Url: http://artulab.com/gitweb/?a=commitdiff_plain;h=793984b26894fd79a35801a3a6ad4743b7a4e737;p=openbsd GC remnants of pipe support, long gone. Display an error message for non found packages, in addition to setting the exit code. --- diff --git a/usr.sbin/pkg_add/OpenBSD/PackageRepositoryList.pm b/usr.sbin/pkg_add/OpenBSD/PackageRepositoryList.pm index 95bd49c653f..1c84110fc06 100644 --- a/usr.sbin/pkg_add/OpenBSD/PackageRepositoryList.pm +++ b/usr.sbin/pkg_add/OpenBSD/PackageRepositoryList.pm @@ -1,5 +1,5 @@ # ex:ts=8 sw=4: -# $OpenBSD: PackageRepositoryList.pm,v 1.33 2023/06/13 09:07:17 espie Exp $ +# $OpenBSD: PackageRepositoryList.pm,v 1.34 2023/06/14 09:59:09 espie Exp $ # # Copyright (c) 2003-2006 Marc Espie # @@ -48,9 +48,6 @@ sub prepend($self, @p) sub do_something($self, $do, $pkgname, @args) { - if (defined $pkgname && $pkgname eq '-') { - return OpenBSD::PackageRepository->pipe->new($self->{state})->$do($pkgname, @args); - } for my $repo (@{$self->{l}}) { my $r = $repo->$do($pkgname, @args); return $r if defined $r; diff --git a/usr.sbin/pkg_add/OpenBSD/PkgInfo.pm b/usr.sbin/pkg_add/OpenBSD/PkgInfo.pm index f88def39378..cf43a0b8d44 100644 --- a/usr.sbin/pkg_add/OpenBSD/PkgInfo.pm +++ b/usr.sbin/pkg_add/OpenBSD/PkgInfo.pm @@ -1,6 +1,6 @@ #! /usr/bin/perl # ex:ts=8 sw=4: -# $OpenBSD: PkgInfo.pm,v 1.51 2023/06/13 09:07:17 espie Exp $ +# $OpenBSD: PkgInfo.pm,v 1.52 2023/06/14 09:59:09 espie Exp $ # # Copyright (c) 2003-2014 Marc Espie # @@ -642,6 +642,7 @@ sub parse_and_run($self, $cmd) $self->print_info($state, $pkgname, $handle); })) { $exit_code = 1; + $state->errsay("Can't find #1", $pkg); } } for my $extra (@extra) {