From owner-freebsd-bugs Sat Sep 5 06:10:09 1998 Return-Path: Received: (from majordom@localhost) by hub.freebsd.org (8.8.8/8.8.8) id GAA23169 for freebsd-bugs-outgoing; Sat, 5 Sep 1998 06:10:09 -0700 (PDT) (envelope-from owner-freebsd-bugs@FreeBSD.ORG) Received: from freefall.freebsd.org (freefall.FreeBSD.ORG [204.216.27.21]) by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id GAA23162 for ; Sat, 5 Sep 1998 06:10:07 -0700 (PDT) (envelope-from gnats@FreeBSD.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.8.8/8.8.5) id GAA28779; Sat, 5 Sep 1998 06:10:00 -0700 (PDT) Received: from istari.home.net (cc158233-a.catv1.md.home.com [24.3.25.17]) by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id GAA22501 for ; Sat, 5 Sep 1998 06:01:16 -0700 (PDT) (envelope-from sjr@home.net) Received: (from sjr@localhost) by istari.home.net (8.8.8/8.8.6) id JAA09148; Sat, 5 Sep 1998 09:00:06 -0400 (EDT) Message-Id: <199809051300.JAA09148@istari.home.net> Date: Sat, 5 Sep 1998 09:00:06 -0400 (EDT) From: sjr@home.net Reply-To: sjr@home.net To: FreeBSD-gnats-submit@FreeBSD.ORG X-Send-Pr-Version: 3.2 Subject: bin/7835: whereis doesn't find sources in /usr/src/contrib Sender: owner-freebsd-bugs@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.org >Number: 7835 >Category: bin >Synopsis: whereis doesn't find sources in /usr/src/contrib >Confidential: no >Severity: serious >Priority: low >Responsible: freebsd-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Sat Sep 5 06:10:00 PDT 1998 >Last-Modified: >Originator: Stephen J. Roznowski >Organization: >Release: FreeBSD 3.0-CURRENT i386 >Environment: $Id: whereis.pl,v 1.5 1997/12/22 19:11:28 ache Exp $ >Description: whereis doesn't search /usr/src/contrib, and stops at first match. >How-To-Repeat: % whereis libpcap libpcap: % whereis cvs cvs: /usr/bin/cvs /usr/share/man/man1/cvs.1.gz \ /usr/src/gnu/usr.bin/cvs After patch. % whereis libpcap libpcap: /usr/src/contrib/libpcap % whereis cvs cvs: /usr/bin/cvs /usr/share/man/man1/cvs.1.gz \ /usr/src/gnu/usr.bin/cvs /usr/src/contrib/cvs >Fix: --- usr.bin/whereis.pl Wed Dec 24 09:15:13 1997 +++ usr.bin/whereis.pl.new Sat Sep 5 08:53:27 1998 @@ -144,7 +144,7 @@ "/usr/src/usr.sbin", "/usr/src/libexec", "/usr/src/gnu/bin", "/usr/src/gnu/usr.bin", "/usr/src/gnu/sbin", "/usr/src/gnu/usr.sbin", - "/usr/src/gnu/libexec"); + "/usr/src/gnu/libexec", "/usr/src/contrib"); # # if /usr/ports exists, look in all its subdirs, too @@ -213,7 +213,7 @@ $found = 0; $unusual++; foreach (@sources) { - $line .= " $_/$name", $unusual--, $found++, last if -d "$_/$name"; + $line .= " $_/$name", $unusual--, $found++ if -d "$_/$name"; } # # If not yet found, ask locate(1) to do the search for us. >Audit-Trail: >Unformatted: To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-bugs" in the body of the message