From owner-freebsd-bugs Tue Dec 31 01:51:08 1996 Return-Path: Received: (from root@localhost) by freefall.freebsd.org (8.8.4/8.8.4) id BAA22403 for bugs-outgoing; Tue, 31 Dec 1996 01:51:08 -0800 (PST) Received: from irz301.inf.tu-dresden.de (irz301.inf.tu-dresden.de [141.76.1.11]) by freefall.freebsd.org (8.8.4/8.8.4) with SMTP id BAA22396 for ; Tue, 31 Dec 1996 01:51:03 -0800 (PST) Received: from sax.sax.de (sax.sax.de [193.175.26.33]) by irz301.inf.tu-dresden.de (8.6.12/8.6.12-s1) with ESMTP id KAA09050; Tue, 31 Dec 1996 10:51:01 +0100 Received: (from uucp@localhost) by sax.sax.de (8.6.12/8.6.12-s1) with UUCP id KAA26306; Tue, 31 Dec 1996 10:51:00 +0100 Received: (from j@localhost) by uriah.heep.sax.de (8.8.4/8.6.9) id KAA23702; Tue, 31 Dec 1996 10:30:45 +0100 (MET) From: J Wunsch Message-Id: <199612310930.KAA23702@uriah.heep.sax.de> Subject: Re: bin/2331: strange output of sh's pwd on symlinked directories To: bde@zeta.org.au (Bruce Evans) Date: Tue, 31 Dec 1996 10:30:45 +0100 (MET) Cc: Helbig@MX.BA-Stuttgart.De, roberto@keltia.freenix.fr, freebsd-bugs@FreeBSD.org Reply-To: joerg_wunsch@uriah.heep.sax.de (Joerg Wunsch) In-Reply-To: <199612310631.RAA26286@godzilla.zeta.org.au> from Bruce Evans at "Dec 31, 96 05:31:04 pm" X-Phone: +49-351-2012 669 X-PGP-Fingerprint: DC 47 E6 E4 FF A6 E9 8F 93 21 E0 7D F9 12 D6 4E X-Mailer: ELM [version 2.4ME+ PL17 (25)] MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: owner-bugs@FreeBSD.org X-Loop: FreeBSD.org Precedence: bulk As Bruce Evans wrote: > >It is not really a bug, jsust use a modern shell :-) > > It is really a bug. sh's pwd used to be equivalent to /bin/pwd. Now > it is broken after `cd symlink; cd ..'. That's not a bug. That's ksh compatible now, whether you like it or not. :-} Since ksh is Posix, it cannot be a bug, by definition. :-P I always hated this ksh braindeadness where you gotta explicitly call /bin/pwd if you want the ``canonical pathname''. However, since Posix has sanctioned all bugfeatures of Mr. Korn, we have to live with this situation anyway. Our /bin/sh used to be one of the last remaining shells where the output of the builtin pwd was still similar to /bin/pwd (no surprise, since it did call /bin/pwd!). All the other remaining shells on our platform didn't do it: j@uriah 381% sh $ pwd /usr/src/sys $ j@uriah 382% ksh $ pwd /sys $ j@uriah 383% zsh uriah% pwd /sys uriah% j@uriah 384% bash bash$ pwd /sys bash$ exit (My /bin/sh still seems to be the old version. Mmmmaybe.) Speaking about shells, there used to be a pointer to a BSD version of the genuine ksh which i eventually lost. Can somebody point me again to it? -- cheers, J"org joerg_wunsch@uriah.heep.sax.de -- http://www.sax.de/~joerg/ -- NIC: JW11-RIPE Never trust an operating system you don't have sources for. ;-)