NetBSD Problem Report #40543
From jmcneill@black.invisible.ca Mon Feb 2 23:03:36 2009
Return-Path: <jmcneill@black.invisible.ca>
Received: from mail.netbsd.org (mail.netbsd.org [204.152.190.11])
by narn.NetBSD.org (Postfix) with ESMTP id 567AC63B879
for <gnats-bugs@gnats.NetBSD.org>; Mon, 2 Feb 2009 23:03:36 +0000 (UTC)
Message-Id: <20090202230320.10A0F7D9F07@black.invisible.ca>
Date: Mon, 2 Feb 2009 18:03:19 -0500 (EST)
From: jmcneill@invisible.ca
Reply-To: jmcneill@invisible.ca
To: gnats-bugs@gnats.NetBSD.org
Subject: ldd looks weird when run against a nonexistent file
X-Send-Pr-Version: 3.95
>Number: 40543
>Category: bin
>Synopsis: ldd looks weird when run against a nonexistent file
>Confidential: no
>Severity: non-critical
>Priority: low
>Responsible: mrg
>State: closed
>Class: sw-bug
>Submitter-Id: net
>Arrival-Date: Mon Feb 02 23:05:00 +0000 2009
>Closed-Date: Thu Mar 05 05:29:20 +0000 2009
>Last-Modified: Thu Mar 05 05:29:20 +0000 2009
>Originator: Jared D. McNeill
>Release: NetBSD 5.99.7
>Organization:
>Environment:
System: NetBSD black.invisible.ca 5.99.7 NetBSD 5.99.7 (GENERIC) #2: Wed Jan 28 20:31:30 EST 2009 jmcneill@black.invisible.ca:/export/home/jmcneill/branches/HEAD/src/sys/arch/amd64/compile/obj/GENERIC amd64
Architecture: x86_64
Machine: amd64
>Description:
Old NetBSD used to do:
$ ldd /asdf
ldd: /asdf: No such file or directory
Now it looks funny.
>How-To-Repeat:
$ ldd /asdf
ldd: /asdf: No such file or directory
ldd: /asdf: No such file or directory
ldd: /asdf: No such file or directory
ldd: (null)
>Fix:
>Release-Note:
>Audit-Trail:
Responsible-Changed-From-To: bin-bug-people->mrg
Responsible-Changed-By: mrg@NetBSD.org
Responsible-Changed-When: Tue, 03 Feb 2009 02:39:44 +0000
Responsible-Changed-Why:
i think i have a patch for this, i just need to test it a bit more.
State-Changed-From-To: open->analyzed
State-Changed-By: mrg@NetBSD.org
State-Changed-When: Tue, 03 Feb 2009 02:39:44 +0000
State-Changed-Why:
problem is that multiple parts try to open the missing file and print a
message when it fails.
State-Changed-From-To: analyzed->feedback
State-Changed-By: mrg@NetBSD.org
State-Changed-When: Tue, 03 Feb 2009 03:01:18 +0000
State-Changed-Why:
this should be fixed, please confirm. :)
From: matthew green <mrg@netbsd.org>
To: gnats-bugs@gnats.NetBSD.org
Cc:
Subject: PR/40543 CVS commit: src/usr.bin/ldd
Date: Tue, 3 Feb 2009 03:01:02 +0000 (UTC)
Module Name: src
Committed By: mrg
Date: Tue Feb 3 03:01:02 UTC 2009
Modified Files:
src/usr.bin/ldd: ldd.c ldd.h ldd_aout.c ldd_elfxx.c
Log Message:
rework the main loop and handlers:
- open() and close() the file in the main loop
- pass the fd down into the handlers
- use _rtld_error() in ELFNAME(ldd)
this fixes PR#40543 and also makes error messages look better.
To generate a diff of this commit:
cvs rdiff -r1.4 -r1.5 src/usr.bin/ldd/ldd.c
cvs rdiff -r1.1 -r1.2 src/usr.bin/ldd/ldd.h src/usr.bin/ldd/ldd_elfxx.c
cvs rdiff -r1.2 -r1.3 src/usr.bin/ldd/ldd_aout.c
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
From: "Jared D. McNeill" <jmcneill@invisible.ca>
To: gnats-bugs@NetBSD.org
Cc: mrg@NetBSD.org, netbsd-bugs@netbsd.org, gnats-admin@netbsd.org
Subject: Re: bin/40543 (ldd looks weird when run against a nonexistent file)
Date: Mon, 02 Feb 2009 22:18:24 -0500
On 2/2/2009 10:01 PM, mrg@NetBSD.org wrote:
> Synopsis: ldd looks weird when run against a nonexistent file
>
> State-Changed-From-To: analyzed->feedback
> State-Changed-By: mrg@NetBSD.org
> State-Changed-When: Tue, 03 Feb 2009 03:01:18 +0000
> State-Changed-Why:
> this should be fixed, please confirm. :)
Looks good, thanks!
From: Soren Jacobsen <snj@netbsd.org>
To: gnats-bugs@gnats.NetBSD.org
Cc:
Subject: PR/40543 CVS commit: [netbsd-5] src/usr.bin/ldd
Date: Wed, 25 Feb 2009 03:09:31 +0000 (UTC)
Module Name: src
Committed By: snj
Date: Wed Feb 25 03:09:31 UTC 2009
Modified Files:
src/usr.bin/ldd [netbsd-5]: ldd.c ldd.h ldd_aout.c ldd_elfxx.c
Log Message:
Pull up following revision(s) (requested by mrg in ticket #483):
usr.bin/ldd/ldd.c: revision 1.5
usr.bin/ldd/ldd.h: revision 1.2
usr.bin/ldd/ldd_aout.c: revision 1.3
usr.bin/ldd/ldd_elfxx.c: revision 1.2
rework the main loop and handlers:
- - open() and close() the file in the main loop
- - pass the fd down into the handlers
- - use _rtld_error() in ELFNAME(ldd)
this fixes PR#40543 and also makes error messages look better.
To generate a diff of this commit:
cvs rdiff -r1.2.12.1 -r1.2.12.2 src/usr.bin/ldd/ldd.c
cvs rdiff -r1.1.2.2 -r1.1.2.3 src/usr.bin/ldd/ldd.h \
src/usr.bin/ldd/ldd_elfxx.c
cvs rdiff -r1.2.2.3 -r1.2.2.4 src/usr.bin/ldd/ldd_aout.c
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
State-Changed-From-To: feedback->closed
State-Changed-By: mrg@NetBSD.org
State-Changed-When: Thu, 05 Mar 2009 05:29:20 +0000
State-Changed-Why:
pulled up to -5.
>Unformatted:
(Contact us)
$NetBSD: query-full-pr,v 1.39 2013/11/01 18:47:49 spz Exp $
$NetBSD: gnats_config.sh,v 1.8 2006/05/07 09:23:38 tsutsui Exp $
Copyright © 1994-2007
The NetBSD Foundation, Inc. ALL RIGHTS RESERVED.