Date: Wed, 13 Mar 2013 11:37:58 +0100 From: Matthias Andree <mandree@FreeBSD.org> To: FreeBSD-gnats-submit@freebsd.org Subject: ports/176925: ports-mgmt/pkg: pkg version fails if cwd no longer exists Message-ID: <E1UFj4I-000EdL-4h@apollo.emma.line.org> Resent-Message-ID: <201303132040.r2DKe0Ks048479@freefall.freebsd.org>
next in thread | raw e-mail | index | archive | help
>Number: 176925 >Category: ports >Synopsis: ports-mgmt/pkg: pkg version fails if cwd no longer exists >Confidential: no >Severity: non-critical >Priority: low >Responsible: freebsd-ports-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Wed Mar 13 20:40:00 UTC 2013 >Closed-Date: >Last-Modified: >Originator: Matthias Andree >Release: FreeBSD 9.1-RELEASE amd64 >Organization: FreeBSD ports >Environment: System: FreeBSD apollo.emma.line.org 9.1-RELEASE FreeBSD 9.1-RELEASE #2 r244869: Sun Dec 30 22:05:16 CET 2012 toor@apollo.emma.line.org:/usr/obj/usr/src/sys/GENERIC amd64 >Description: Greetings, pkg version appears to have difficulties determining the up-to-date state of its ports if the current working directory has been removed. Now, this may belong in the "if it hurts, then why do you do it" category but I thought to report it nonetheless. >How-To-Repeat: cd /tmp mkdir foo cd foo rmdir ../foo pkg version This emits lots of port names with a question mark as status, as in: pkg version apr-1.4.6.1.4.1_3 ? asciidoc-8.6.8_1 ? autoconf-2.69 ? ... whereas, after a cd /tmp, pkg version would show this instead: apr-1.4.6.1.4.1_3 = asciidoc-8.6.8_1 = autoconf-2.69 = ... >Fix: If the current working directory must exist for pkg options, the pkg program should arguably enforce that, and either report a pertinent error, or perhaps just "chdir("/") to sidestep the issue. >Release-Note: >Audit-Trail: >Unformatted:
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?E1UFj4I-000EdL-4h>