From 7dd131084e34f4727b58d59430a26a16cad19f7d Mon Sep 17 00:00:00 2001 From: Marc Espie Date: Tue, 5 Oct 2004 19:44:16 +0000 Subject: unbreak pure comments, handle @option at new level. --- usr.sbin/pkg_add/OpenBSD/PackingElement.pm | 14 ++++++-------- 1 file changed, 6 insertions(+), 8 deletions(-) (limited to 'usr.sbin') diff --git a/usr.sbin/pkg_add/OpenBSD/PackingElement.pm b/usr.sbin/pkg_add/OpenBSD/PackingElement.pm index 47df169f03f..5de40ed7dec 100644 --- a/usr.sbin/pkg_add/OpenBSD/PackingElement.pm +++ b/usr.sbin/pkg_add/OpenBSD/PackingElement.pm @@ -1,5 +1,5 @@ # ex:ts=8 sw=4: -# $OpenBSD: PackingElement.pm,v 1.41 2004/10/05 19:35:49 espie Exp $ +# $OpenBSD: PackingElement.pm,v 1.42 2004/10/05 19:44:15 espie Exp $ # # Copyright (c) 2003-2004 Marc Espie # @@ -502,7 +502,7 @@ sub add $plist->{state}->{nochecksum} = 1; return undef; } else { - return $class->SUPER::add(@args); + return $class->SUPER::add($plist, @args); } } @@ -571,15 +571,13 @@ our @ISA=qw(OpenBSD::PackingElement::Meta); __PACKAGE__->setKeyword('option'); sub keyword() { 'option' } -sub add +sub new { - my ($class, $plist, @args) = @_; + my ($class, @args) = @_; if ($args[0] eq 'no-default-conflict') { - shift; - return OpenBSD::PackingElement::NoDefaultConflict->add($plist); + return OpenBSD::PackingElement::NoDefaultConflict->new(); } elsif ($args[0] eq 'manual-installation') { - shift; - return OpenBSD::PackingElement::ManualInstallation->add($plist); + return OpenBSD::PackingElement::ManualInstallation->new(); } else { die "Unknown option: $args[0]"; } -- cgit v1.2.3