From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 24690 invoked from network); 21 Apr 1997 14:25:26 -0000 Received: from euclid.skiles.gatech.edu (list@130.207.146.50) by ns1.primenet.com.au with SMTP; 21 Apr 1997 14:25:26 -0000 Received: (from list@localhost) by euclid.skiles.gatech.edu (8.7.3/8.7.3) id KAA01428; Mon, 21 Apr 1997 10:16:28 -0400 (EDT) Resent-Date: Mon, 21 Apr 1997 10:16:28 -0400 (EDT) Date: Mon, 21 Apr 1997 16:34:04 +0200 Message-Id: <199704211434.QAA04441@Laden3.ilk.de> From: "Juergen A. Erhard" To: zefram@dcs.warwick.ac.uk CC: zsh-workers@math.gatech.edu In-reply-to: <807.199704111410@stone.dcs.warwick.ac.uk> (message from Zefram on Fri, 11 Apr 1997 15:10:01 +0100 (BST)) Subject: Re: whence following symlinks Resent-Message-ID: <"XUICD1.0.DM.xQtMp"@euclid> Resent-From: zsh-workers@math.gatech.edu X-Mailing-List: archive/latest/3082 X-Loop: zsh-workers@math.gatech.edu Precedence: list Resent-Sender: zsh-workers-request@math.gatech.edu -----BEGIN PGP SIGNED MESSAGE----- >>>>> "Zefram" == Zefram writes: Zefram> Juergen A. Erhard wrote: >> Unfortunately, 'whence -ms' doesn't work as expected, because '-m' >> jumps to a different code section, and that code doesn't care for >> '-s'. Zefram> You could duplicate the new code, or use the hashtable printnode() method. Okay, I'll check this printnode() out... >> ! /* temporarily set CHASELINKS */ >> ! chase = isset(CHASELINKS); >> ! dosetopt(CHASELINKS, 1, 0); Zefram> ... >> ! /* revert setting of CHASELINKS */ >> ! dosetopt(CHASELINKS, chase, 0); Zefram> Do Zefram> chase = opts[CHASELINKS]; Zefram> opts[CHASELINKS] = 1; Zefram> ... Zefram> opts[CHASELINKS] = chase; Well, there's a reason to my madness ;-)... I simply don't like directly editing some data structures that might or might not transmogrify into something completely different... On the other hand, you're right in your (implied) statement that dosetopt might carry too much overhead... So, if TPTB gives me the ok to use your suggestion (that is, they/he/she/it guarantees opts to stay a simple int[]), I will. >> ! /* throw away try_link... hope this is the right fn */ >> ! zsfree(try_link); Zefram> It is the right function. Thanks. I'd really love to see a couple more comments on this beast. Especially on fns like 'xsymlink'... I had to RTFS to find out I had to free(3) the result... and had to guess (more or less) on zsfree (the doc on the mem-mgt could be better... or maybe I could be smarter ;-) Zefram> -zefram Bye, J - -- Juergen A. Erhard (that ue is actually \"u (TeX) or ü (HTML/SGML)) eMail: jae@laden.ilk.de | snailMail: Belfortstr. 6; 76133 Karlsruhe; GERMANY | pros do it for money, phone: +49 721 27326 | amateurs out of love. WWW: http://members.tripod.com/~Juergen_Erhard/ | -----BEGIN PGP SIGNATURE----- Version: 2.6.3ia Charset: noconv Comment: Processed by Mailcrypt 3.4, an Emacs/PGP interface iQEVAwUBM0/sAwIG66LugGzRAQH+AwgAn3nUBG6elVvRrbKBGPv9xfYzReQxT8k0 hdvJhzPwJR6gXGREjcwEs1+agl/tvE/FENt+7eG3QtKCPo/1jlZTWX1mkkLFUsox qabkAB42xn0eLHy9MFVpA4sKA5uh1XeOEZ1rRSU/QsN8RRGcWqzc3PiWgDt+dukq 3AZQ32vPYMMersdy9VA5kGCXjDDv5t0w6XoaIZKxBlBjGcYJxRYHrwtZpi0QhQUH 2Mm9+VTLux0ZcqklZ3NO5D7le+W6N0vkchjN7hH2pF1MADcXoxaKSShFgBmHy8XK k2KbA6iuYBO/1ksgrrfHnkuaoKwNVH6Miyk9WsE3f3GBXkLO+ydUbw== =ocZm -----END PGP SIGNATURE-----