From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 26900 invoked from network); 27 Apr 2007 16:02:45 -0000 X-Spam-Checker-Version: SpamAssassin 3.1.8 (2007-02-13) on f.primenet.com.au X-Spam-Level: X-Spam-Status: No, score=-2.5 required=5.0 tests=AWL,BAYES_00,FORGED_RCVD_HELO autolearn=ham version=3.1.8 Received: from news.dotsrc.org (HELO a.mx.sunsite.dk) (130.225.247.88) by ns1.primenet.com.au with SMTP; 27 Apr 2007 16:02:45 -0000 Received-SPF: none (ns1.primenet.com.au: domain at sunsite.dk does not designate permitted sender hosts) Received: (qmail 64822 invoked from network); 27 Apr 2007 16:02:39 -0000 Received: from sunsite.dk (130.225.247.90) by a.mx.sunsite.dk with SMTP; 27 Apr 2007 16:02:39 -0000 Received: (qmail 3129 invoked by alias); 27 Apr 2007 16:02:35 -0000 Mailing-List: contact zsh-workers-help@sunsite.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 23337 Received: (qmail 3114 invoked from network); 27 Apr 2007 16:02:33 -0000 Received: from news.dotsrc.org (HELO a.mx.sunsite.dk) (130.225.247.88) by sunsite.dk with SMTP; 27 Apr 2007 16:02:33 -0000 Received: (qmail 64393 invoked from network); 27 Apr 2007 16:02:33 -0000 Received: from cluster-d.mailcontrol.com (217.69.20.190) by a.mx.sunsite.dk with SMTP; 27 Apr 2007 16:02:29 -0000 Received: from rly13d.srv.mailcontrol.com (localhost.localdomain [127.0.0.1]) by rly13d.srv.mailcontrol.com (MailControl) with ESMTP id l3RG2QsA018486 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO) for ; Fri, 27 Apr 2007 17:02:26 +0100 Received: from submission.mailcontrol.com (submission.mailcontrol.com [86.111.216.190]) by rly13d.srv.mailcontrol.com (MailControl) id l3RG1rxc017856 for zsh-workers@sunsite.dk; Fri, 27 Apr 2007 17:01:53 +0100 Received: from cameurexb01.EUROPE.ROOT.PRI ([62.189.241.200]) by rly13d-eth0.srv.mailcontrol.com (envelope-sender Peter.Stephenson@csr.com) (MIMEDefang) with ESMTP id l3RG1jFp017681; Fri, 27 Apr 2007 17:01:53 +0100 (BST) Received: from news01.csr.com ([10.103.143.38]) by cameurexb01.EUROPE.ROOT.PRI with Microsoft SMTPSVC(6.0.3790.1830); Fri, 27 Apr 2007 17:01:45 +0100 Date: Fri, 27 Apr 2007 17:01:45 +0100 From: Peter Stephenson To: Fernando Vezzosi , zsh-workers@sunsite.dk Subject: Re: BUG: "setopt autocd" and auto-cd completion of dirs with funny (Unicode) chars Message-Id: <20070427170145.a75a90b1.pws@csr.com> In-Reply-To: <20070427144905.GA1379@lothlorien.passione> References: <20070427144905.GA1379@lothlorien.passione> Organization: Cambridge Silicon Radio X-Mailer: Sylpheed version 2.2.10 (GTK+ 2.10.8; i386-redhat-linux-gnu) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-OriginalArrivalTime: 27 Apr 2007 16:01:45.0523 (UTC) FILETIME=[5AC70830:01C788E5] X-Scanned-By: MailControl A-07-07-00 (www.mailcontrol.com) on 10.68.1.123 Fernando Vezzosi wrote: > Hi -workers, > zsh-beta 4.3.2-dev-1+20070413-1 on Debian Sid (i686-pc-linux-gnu) > here.. > > I use zsh-beta because the plain zsh package doesn't complete > Unicode (UTF-8) filenames and dirs. With zsh-beta it's much better, > but it fails when auto-cd`ing into some Unicode-named directory.. Aha... you're using raw out-of-the-box completion, not compinit, right? Index: Src/Zle/compctl.c =================================================================== RCS file: /cvsroot/zsh/zsh/Src/Zle/compctl.c,v retrieving revision 1.31 diff -u -r1.31 compctl.c --- Src/Zle/compctl.c 3 Dec 2006 21:07:18 -0000 1.31 +++ Src/Zle/compctl.c 27 Apr 2007 16:00:44 -0000 @@ -2188,9 +2188,14 @@ if (!test) continue; if (!all) { + char *ums; + int umlen; /* We still have to check the file type, so prepare * * the path buffer by appending the filename. */ - strcpy(q, n); + ums = dupstring(n); + unmetafy(ums, ¨en); + memcpy(q, ums, umlen); + q[umlen] = '\0'; /* And do the stat. */ if (stat(p, &buf) < 0) continue; -- Peter Stephenson Software Engineer CSR PLC, Churchill House, Cambridge Business Park, Cowley Road Cambridge, CB4 0WZ, UK Tel: +44 (0)1223 692070 To access the latest news from CSR copy this link into a web browser: http://www.csr.com/email_sig.php To get further information regarding CSR, please visit our Investor Relations page at http://ir.csr.com/csr/about/overview