From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 7528 invoked from network); 14 Jun 2000 14:37:16 -0000 Received: from sunsite.auc.dk (130.225.51.30) by ns1.primenet.com.au with SMTP; 14 Jun 2000 14:37:16 -0000 Received: (qmail 16079 invoked by alias); 14 Jun 2000 14:36:59 -0000 Mailing-List: contact zsh-workers-help@sunsite.auc.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 11898 Received: (qmail 16048 invoked from network); 14 Jun 2000 14:36:57 -0000 Date: Wed, 14 Jun 2000 16:36:54 +0200 (MET DST) Message-Id: <200006141436.QAA03623@beta.informatik.hu-berlin.de> From: Sven Wischnowsky To: zsh-workers@sunsite.auc.dk In-reply-to: "Bart Schaefer"'s message of Wed, 14 Jun 2000 14:23:03 +0000 Subject: Re: Wordcode functions with empty bodies Bart Schaefer wrote: > On Jun 14, 8:14am, Sven Wischnowsky wrote: > } Subject: Re: Wordcode functions with empty bodies > } > } I had a little debugging session yesterday evening... I could > } reproduce the segv with the `prompt' thing (although I had to invoke > } `prompt bart' a second time with some other command before it to make > } it go kaboom). > } > } I could not, however, see any problems with bld_eprog(). In which way > } do you think it produces garbled eprogs? (I mean, what do those eprogs > } look like?) > > They have a `len' of 4 and a `strs' that points to four bytes of garbage. > The crashes appear to happen after dupeprog() copies `strs' -- the new > copy often ends up pointing to a different four bytes of garbage. I almost thought that you meant this... that's ok, even if it looks weird. `len' is the total length of the memory block used for patterns, the word code and the string table. `prog' and `strs' point into that memory at the rightpositions, `strs' after the word code. Since there are no strings it points to the memory *after* the word code... but it will never be used. Bye Sven -- Sven Wischnowsky wischnow@informatik.hu-berlin.de