diff options
author | Marc Espie <espie@cvs.openbsd.org> | 2014-02-03 12:03:02 +0000 |
---|---|---|
committer | Marc Espie <espie@cvs.openbsd.org> | 2014-02-03 12:03:02 +0000 |
commit | a8f74652e89d1934187d8f5147ed08a5877a4c17 (patch) | |
tree | 7262354ba8acd81830874f36f9b28294b9e5c7d2 /usr.sbin/pkg_add/OpenBSD | |
parent | d92324d5ec21f829ea2c34f0a85d1480a96d449d (diff) |
don't really need exactstem, the initial grep is good enough
Diffstat (limited to 'usr.sbin/pkg_add/OpenBSD')
-rw-r--r-- | usr.sbin/pkg_add/OpenBSD/PkgSpec.pm | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/usr.sbin/pkg_add/OpenBSD/PkgSpec.pm b/usr.sbin/pkg_add/OpenBSD/PkgSpec.pm index 5c3c9f7e392..b2908df4f80 100644 --- a/usr.sbin/pkg_add/OpenBSD/PkgSpec.pm +++ b/usr.sbin/pkg_add/OpenBSD/PkgSpec.pm @@ -1,5 +1,5 @@ # ex:ts=8 sw=4: -# $OpenBSD: PkgSpec.pm,v 1.42 2014/01/31 10:49:53 espie Exp $ +# $OpenBSD: PkgSpec.pm,v 1.43 2014/02/03 12:03:01 espie Exp $ # # Copyright (c) 2003-2007 Marc Espie <espie@openbsd.org> # @@ -309,10 +309,8 @@ sub new }, $class; if ($with_partial) { - $o->{exactstem} = qr{^(?:partial\-)*$stemspec$}; $o->{fuzzystem} = qr{^(?:partial\-)*$stemspec\-\d.*$}; } else { - $o->{exactstem} = qr{^$stemspec$}; $o->{fuzzystem} = qr{^$stemspec\-\d.*$}; } if (@$constraints != 0) { @@ -335,7 +333,6 @@ sub match_ref LOOP1: for my $s (grep(/$o->{fuzzystem}/, @$list)) { my $name = OpenBSD::PackageName->from_string($s); - next unless $name->{stem} =~ m/^$o->{exactstem}$/; if (defined $o->{constraints}) { for my $c (@{$o->{constraints}}) { next LOOP1 unless $c->match($name); @@ -366,7 +363,6 @@ sub match_locations LOOP2: for my $s (grep { $_->name =~ m/$o->{fuzzystem}/} @$list) { my $name = $s->pkgname; - next unless $name->{stem} =~ m/^$o->{exactstem}$/; if (defined $o->{constraints}) { for my $c (@{$o->{constraints}}) { next LOOP2 unless $c->match($name); |