From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 8489 invoked from network); 20 Jan 2009 10:39:34 -0000 X-Spam-Checker-Version: SpamAssassin 3.2.5 (2008-06-10) on f.primenet.com.au X-Spam-Level: X-Spam-Status: No, score=-2.3 required=5.0 tests=AWL,BAYES_00 autolearn=ham version=3.2.5 Received: from news.dotsrc.org (HELO a.mx.sunsite.dk) (130.225.247.88) by ns1.primenet.com.au with SMTP; 20 Jan 2009 10:39:34 -0000 Received-SPF: none (ns1.primenet.com.au: domain at sunsite.dk does not designate permitted sender hosts) Received: (qmail 4121 invoked from network); 20 Jan 2009 10:39:27 -0000 Received: from sunsite.dk (130.225.247.90) by a.mx.sunsite.dk with SMTP; 20 Jan 2009 10:39:27 -0000 Received: (qmail 2011 invoked by alias); 20 Jan 2009 10:39:22 -0000 Mailing-List: contact zsh-workers-help@sunsite.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 26373 Received: (qmail 1999 invoked from network); 20 Jan 2009 10:39:21 -0000 Received: from bifrost.dotsrc.org (130.225.254.106) by sunsite.dk with SMTP; 20 Jan 2009 10:39:21 -0000 Received: from cluster-d.mailcontrol.com (cluster-d.mailcontrol.com [85.115.60.190]) by bifrost.dotsrc.org (Postfix) with ESMTPS id 32DB080271F0 for ; Tue, 20 Jan 2009 11:39:18 +0100 (CET) Received: from cameurexb01.EUROPE.ROOT.PRI ([193.128.72.68]) by rly39d.srv.mailcontrol.com (MailControl) with ESMTP id n0KAd7Os028372 for ; Tue, 20 Jan 2009 10:39:17 GMT Received: from news01 ([10.103.143.38]) by cameurexb01.EUROPE.ROOT.PRI with Microsoft SMTPSVC(6.0.3790.3959); Tue, 20 Jan 2009 10:39:13 +0000 Date: Tue, 20 Jan 2009 10:39:07 +0000 From: Peter Stephenson To: zsh-workers@sunsite.dk Subject: Re: 4.3.9: frequent crashes in completion menu selection Message-ID: <20090120103907.1193e13c@news01> In-Reply-To: <691a5d910901181547r4d569891mca406c789af2b35@mail.gmail.com> References: <200901081526.48797.arvidjaar@newmail.ru> <200901081230.n08CUXTB010409@news01.csr.com> <200901181447.54147.arvidjaar@newmail.ru> <2d460de70901181124l4370b10kcb2c06569607a501@mail.gmail.com> <691a5d910901181547r4d569891mca406c789af2b35@mail.gmail.com> Organization: CSR X-Mailer: Claws Mail 3.5.0 (GTK+ 2.12.8; i386-redhat-linux-gnu) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-OriginalArrivalTime: 20 Jan 2009 10:39:13.0474 (UTC) FILETIME=[55F43220:01C97AEB] X-Scanned-By: MailControl A_08_51_00 (www.mailcontrol.com) on 10.68.0.149 X-Virus-Scanned: ClamAV 0.92.1/8878/Mon Jan 19 23:01:48 2009 on bifrost X-Virus-Status: Clean On Sun, 18 Jan 2009 15:47:31 -0800 Bart Schaefer wrote: > It looks like the loop that tries to locate the highlighted match in > the list of completions is running one line too far, but I can't see > why (a) there is no highlighted match and (b) having a format style > causes this to happen. > > Program received signal SIGSEGV, Segmentation fault. > 0x08109622 in domenuselect (dummy=0x8156c74, dat=0xbfe3d4b0) > at ../../../zsh-4.0/Src/Zle/complist.c:2433 > 2433 if (*p && !mmarked(*p) && **p && mselect Might be this simple: mtab_been_reallocated doesn't work the first time through the loop, because we've just reset some key parameters before the loop, and Andrey's results clearly show this is happening when you start a new completion. That variable was added to fix a bug with redisplaying within menu completion. Index: Src/Zle/complist.c =================================================================== RCS file: /cvsroot/zsh/zsh/Src/Zle/complist.c,v retrieving revision 1.118 diff -u -r1.118 complist.c --- Src/Zle/complist.c 6 Aug 2008 02:21:03 -0000 1.118 +++ Src/Zle/complist.c 20 Jan 2009 10:36:46 -0000 @@ -2421,6 +2421,7 @@ mlines = 999999; mlbeg = 0; molbeg = -42; + mtab_been_reallocated = 0; for (;;) { METACHECK(); -- Peter Stephenson Software Engineer CSR PLC, Churchill House, Cambridge Business Park, Cowley Road Cambridge, CB4 0WZ, UK Tel: +44 (0)1223 692070