From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from gatech.edu (gatech.edu [130.207.244.244]) by werple.mira.net.au (8.6.12/8.6.9) with SMTP id RAA11426 for ; Sun, 4 Jun 1995 17:28:13 +1000 Received: from math (math.skiles.gatech.edu) by gatech.edu with SMTP id AA23257 (5.65c/Gatech-10.0-IDA for ); Sun, 4 Jun 1995 03:27:51 -0400 Received: by math (5.x/SMI-SVR4) id AA02846; Sun, 4 Jun 1995 03:25:38 -0400 Resent-Date: Sun, 04 Jun 1995 19:25:53 +1200 Old-Return-Path: From: Dave Sainty Message-Id: <199506040725.TAA26352@bats.comp.vuw.ac.nz> To: zsh-workers@math.gatech.edu Subject: BIG bug! X-Face: /B9VTI#fcP.}X/h^;-~C,RyvcjB8gD' s!52iF{}"OR9bmoP Resent-From: zsh-workers@math.gatech.edu X-Mailing-List: archive/latest/66 X-Loop: zsh-workers@math.gatech.edu Precedence: list Resent-Sender: zsh-workers-request@math.gatech.edu This bug has a very weird effect that could cause a lot of strife! The effect appears to be that at the end of .'ing a script (including login scripts), zsh is likely to jump back into the middle of the script and start again! This causes infinite loops, or weird errors with no apparent cause (I could not see where the unmatched " was, because my login script was being jumped into halfway through a line with a " near the start!) At the end of the letter is a uuencoded/gzipped script that will show the bug if "zsh -f script-name"'d. It is my login script with everything removed that doesn't affect the bug. Also, the exact size of the file is vital, which is why I'm mailing it as binary. It has a "return" statement strategically placed in the middle of the script, that xtrace shows is executed at the end of the script! Magic! :-) This is visible on Solaris and Alpha/OSF boxes at any rate. This is new since beta 8. In fact, it seems to be Peter Stephenson's fault, if I may point the finger... ;-) The fault appears after applying patch 6160 to exec.c (In which a typo was fixed also by patch 6197, but this does not solve the problem here). This code does very little new, simply exiting under certain conditions, so there must be a logic problem in the condition it exits on. But I don't have a clue what is going on in this code, so I'll leave it to someone who does. (Peter?) And yeah.... That did take a lot of hunting! But I have so much work to do, I was just looking for a reason to procrastinate! :-) Dave.