From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 976 invoked from network); 22 May 2001 07:22:39 -0000 Received: from sunsite.dk (130.225.51.30) by ns1.primenet.com.au with SMTP; 22 May 2001 07:22:39 -0000 Received: (qmail 27231 invoked by alias); 22 May 2001 07:22:32 -0000 Mailing-List: contact zsh-workers-help@sunsite.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 14432 Received: (qmail 27220 invoked from network); 22 May 2001 07:22:31 -0000 Message-ID: To: Paul Ackersviller , zsh-workers@sunsite.dk (Zsh hackers list) Subject: Re: vi editting troubles In-Reply-To: Your message of "Mon, 21 May 2001 12:13:35 PDT." <20010521121334.A24931@flora01.SLAC.Stanford.EDU> Date: Mon, 21 May 2001 20:43:04 +0100 From: Peter Stephenson > Neither `r' or `fc -e -' work, and give me this error. > fc: can't open temp file: bad address Do you have TMPPREFIX set to something invalid? The chunk of code in question is this. The questions are whether we need to make gettempname() more robust about this, and why to goodness the system has decided to set errno to EFAULT instead of ENOENT, which would make the error message rather more understandable. fil = gettempname(); if (((tempfd = open(fil, O_WRONLY | O_CREAT | O_EXCL | O_NOCTTY, 0600)) == -1) || ((out = fdopen(tempfd, "w")) == NULL)) { unqueue_signals(); zwarnnam("fc", "can't open temp file: %e", NULL, errno); } > Another strange thing I notice when I turn on shell tracing is that my > TRAPZERR function runs in the middle of _history_complete_word -- is > there something I should be doing to avoid this? Oh, yuk. We really need some way of getting the effect of `setopt localtraps; unfunction TRAPZERR' in all completion functions. I suppose that means adding it everywhere we already have `setopt localoptions' or `emulate -L zsh' (the latter already sets localtraps). If anybody sees this as their mission in life... -- Peter Stephenson Software Engineer CSR Ltd., Unit 300, Science Park, Milton Road, Cambridge, CB4 0XL, UK Tel: +44 (0)1223 392070 ********************************************************************** The information transmitted is intended only for the person or entity to which it is addressed and may contain confidential and/or privileged material. Any review, retransmission, dissemination or other use of, or taking of any action in reliance upon, this information by persons or entities other than the intended recipient is prohibited. If you received this in error, please contact the sender and delete the material from any computer. **********************************************************************