From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 8959 invoked from network); 16 Aug 2005 17:10:01 -0000 Received: from news.dotsrc.org (HELO a.mx.sunsite.dk) (130.225.247.88) by ns1.primenet.com.au with SMTP; 16 Aug 2005 17:10:01 -0000 Received: (qmail 39008 invoked from network); 16 Aug 2005 17:09:55 -0000 Received: from sunsite.dk (130.225.247.90) by a.mx.sunsite.dk with SMTP; 16 Aug 2005 17:09:55 -0000 Received: (qmail 5276 invoked by alias); 16 Aug 2005 17:09:53 -0000 Mailing-List: contact zsh-workers-help@sunsite.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 21642 Received: (qmail 5266 invoked from network); 16 Aug 2005 17:09:52 -0000 Received: from news.dotsrc.org (HELO a.mx.sunsite.dk) (130.225.247.88) by sunsite.dk with SMTP; 16 Aug 2005 17:09:52 -0000 Received: (qmail 38749 invoked from network); 16 Aug 2005 17:09:52 -0000 Received: from flock1.newmail.ru (212.48.140.157) by a.mx.sunsite.dk with SMTP; 16 Aug 2005 17:09:49 -0000 Received: (qmail 16087 invoked from network); 16 Aug 2005 17:02:20 -0000 Received: from unknown (HELO ?10.0.0.53?) (arvidjaar@newmail.ru@83.237.106.159) by smtpd.newmail.ru with SMTP; 16 Aug 2005 17:02:20 -0000 From: Andrey Borzenkov To: zsh-workers@sunsite.dk Subject: Re: [PATCH] fix recursive ZLE from completion call Date: Tue, 16 Aug 2005 21:09:34 +0400 User-Agent: KMail/1.8.2 References: <200508152207.27813.arvidjaar@newmail.ru> In-Reply-To: <200508152207.27813.arvidjaar@newmail.ru> MIME-Version: 1.0 Content-Type: multipart/signed; boundary="nextPart7449401.QLILSYxthM"; protocol="application/pgp-signature"; micalg=pgp-sha1 Content-Transfer-Encoding: 7bit Message-Id: <200508162109.35277.arvidjaar@newmail.ru> X-Spam-Checker-Version: SpamAssassin 3.0.4 (2005-06-05) on f.primenet.com.au X-Spam-Level: X-Spam-Status: No, score=-2.6 required=5.0 tests=AWL,BAYES_00 autolearn=ham version=3.0.4 --nextPart7449401.QLILSYxthM Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit Content-Disposition: inline No need for extra checks, we know for sure we are inside of completion. Index: Src/Zle/compcore.c =================================================================== RCS file: /cvsroot/zsh/zsh/Src/Zle/compcore.c,v retrieving revision 1.74 diff -u -p -r1.74 compcore.c --- Src/Zle/compcore.c 16 Aug 2005 01:59:43 -0000 1.74 +++ Src/Zle/compcore.c 16 Aug 2005 17:08:26 -0000 @@ -355,15 +355,9 @@ do_completion(UNUSED(Hookdef dummy), Com minfo.cur = NULL; if (useline < 0) { /* unmetafy line before calling ZLE */ - int remetafy = 0; - - if (zlemetaline != NULL) { - unmetafy_line(); - remetafy = 1; - } + unmetafy_line(); ret = selfinsert(zlenoargs); - if (remetafy) - metafy_line(); + metafy_line(); } goto compend; } @@ -379,15 +373,9 @@ do_completion(UNUSED(Hookdef dummy), Com ret = !nmatches; } else if (useline < 0) { /* unmetafy line before calling ZLE */ - int remetafy = 0; - - if (zlemetaline != NULL) { - unmetafy_line(); - remetafy = 1; - } + unmetafy_line(); ret = selfinsert(zlenoargs); - if (remetafy) - metafy_line(); + metafy_line(); } else if (!useline && uselist) { /* All this and the guy only wants to see the list, sigh. */ zlemetacs = 0; --nextPart7449401.QLILSYxthM Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.0 (GNU/Linux) iD8DBQBDAh3PR6LMutpd94wRAlaLAKDIDRGSqTCHiCd7T+VjTfVjMFGNCwCfYmD8 kpG5dKRyBV4zo18eECh0a/I= =k33H -----END PGP SIGNATURE----- --nextPart7449401.QLILSYxthM--