From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: =?ISO-8859-1?Q?Jan_Dj=E4rv?= Newsgroups: gmane.emacs.devel Subject: Re: Fix infinite loop in tex file handling in etags Date: Tue, 08 Aug 2006 11:33:24 +0200 Message-ID: <44D85A64.8030803@swipnet.se> References: <20060807.130110.80242582.jet@gyve.org> NNTP-Posting-Host: main.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Trace: sea.gmane.org 1155029680 3841 80.91.229.2 (8 Aug 2006 09:34:40 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Tue, 8 Aug 2006 09:34:40 +0000 (UTC) Cc: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Tue Aug 08 11:34:37 2006 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by ciao.gmane.org with esmtp (Exim 4.43) id 1GANyo-0000z8-57 for ged-emacs-devel@m.gmane.org; Tue, 08 Aug 2006 11:34:30 +0200 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1GANyn-000835-IB for ged-emacs-devel@m.gmane.org; Tue, 08 Aug 2006 05:34:29 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1GANyS-0007zy-4V for emacs-devel@gnu.org; Tue, 08 Aug 2006 05:34:08 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1GANyN-0007yF-CL for emacs-devel@gnu.org; Tue, 08 Aug 2006 05:34:07 -0400 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1GANyN-0007yA-8G for emacs-devel@gnu.org; Tue, 08 Aug 2006 05:34:03 -0400 Original-Received: from [81.228.8.185] (helo=av12-1-sn2.hy.skanova.net) by monty-python.gnu.org with esmtp (Exim 4.52) id 1GAO2m-0000AT-T1 for emacs-devel@gnu.org; Tue, 08 Aug 2006 05:38:37 -0400 Original-Received: by av12-1-sn2.hy.skanova.net (Postfix, from userid 502) id 497523821B; Tue, 8 Aug 2006 11:33:59 +0200 (CEST) Original-Received: from smtp4-2-sn2.hy.skanova.net (smtp4-2-sn2.hy.skanova.net [81.228.8.93]) by av12-1-sn2.hy.skanova.net (Postfix) with ESMTP id 3C3AC37F83; Tue, 8 Aug 2006 11:33:59 +0200 (CEST) Original-Received: from coolsville.localdomain (81-235-205-204-no59.tbcn.telia.com [81.235.205.204]) by smtp4-2-sn2.hy.skanova.net (Postfix) with ESMTP id 0F3B537E47; Tue, 8 Aug 2006 11:33:53 +0200 (CEST) User-Agent: Thunderbird 1.5.0.4 (X11/20060614) Original-To: Masatake YAMATO In-Reply-To: <20060807.130110.80242582.jet@gyve.org> X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:58173 Archived-At: Masatake YAMATO skrev: > Could someone install this patch, too? > Done. Jan D. > 2006-08-07 Masatake YAMATO > > * etags.c (TEX_mode): Check getc retruns EOF. > File ended without newline causes infinite loop. > > --- orig/lib-src/etags.c > +++ mod/lib-src/etags.c > @@ -5198,7 +5198,7 @@ > { > /* Skip to next line if we hit the TeX comment char. */ > if (c == '%') > - while (c != '\n') > + while (c != '\n' && c != EOF) > c = getc (inf); > else if (c == TEX_LESC || c == TEX_SESC ) > break; > > > _______________________________________________ > Emacs-devel mailing list > Emacs-devel@gnu.org > http://lists.gnu.org/mailman/listinfo/emacs-devel