From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 12045 invoked from network); 20 Jul 1999 08:48:29 -0000 Received: from sunsite.auc.dk (130.225.51.30) by ns1.primenet.com.au with SMTP; 20 Jul 1999 08:48:29 -0000 Received: (qmail 24265 invoked by alias); 20 Jul 1999 08:48:22 -0000 Mailing-List: contact zsh-workers-help@sunsite.auc.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 7217 Received: (qmail 24258 invoked from network); 20 Jul 1999 08:48:21 -0000 Date: Tue, 20 Jul 1999 10:48:17 +0200 (MET DST) Message-Id: <199907200848.KAA01232@beta.informatik.hu-berlin.de> From: Sven Wischnowsky To: zsh-workers@sunsite.auc.dk In-reply-to: "Bart Schaefer"'s message of Mon, 19 Jul 1999 21:46:51 +0000 Subject: Re: Bug in printing of PS4 (the xtrace prompt) Bart Schaefer wrote: > I happened to have xtrace set while running compinit. Here's the tail of > the output: > > +compdump:89> print > +compdump:91> unfunction compdump > +\M-^H\M-9'^H0\M-4\n@^P:92> autoload -U compdump > +compinit:377> unfunction compinit > +(^^]^H0\M-4\n@^P:378> autoload -U compinit > > Looks like it's using a garbaged string as the function name after the > function unfunctions itself. I think it's that easy. There is another `scriptname = ...' in init.c for sourced files -- we shouldn't need a dupstring() there, should we? Bye Sven --- os/exec.c Tue Jul 20 08:54:10 1999 +++ Src/exec.c Tue Jul 20 10:43:17 1999 @@ -2922,7 +2922,7 @@ tab = pparams; oldscriptname = scriptname; - scriptname = name; + scriptname = dupstring(name); oldzoptind = zoptind; zoptind = 1; -- Sven Wischnowsky wischnow@informatik.hu-berlin.de