From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Stephen Berman Newsgroups: gmane.emacs.bugs Subject: bug#15841: Display bugs with cache-long-lines non-nil Date: Tue, 12 Nov 2013 11:03:47 +0100 Message-ID: <87mwla6inw.fsf@rosalinde.fritz.box> References: <871u2xf9st.fsf@gmail.com> <9jiow9uhoa.fsf@fencepost.gnu.org> <87wqkopylw.fsf@gmail.com> <87bo20fh3h.fsf@web.de> <834n7q95d5.fsf@gnu.org> <87r4aqww3j.fsf@nbtrap.com> <83r4aq3s4r.fsf@gnu.org> <87fvr3ni2o.fsf@rosalinde.fritz.box> <877gceo3n9.fsf@rosalinde.fritz.box> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: ger.gmane.org 1384250659 6596 80.91.229.3 (12 Nov 2013 10:04:19 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Tue, 12 Nov 2013 10:04:19 +0000 (UTC) Cc: 15841@debbugs.gnu.org To: Eli Zaretskii Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Tue Nov 12 11:04:21 2013 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1VgApY-0002oq-SQ for geb-bug-gnu-emacs@m.gmane.org; Tue, 12 Nov 2013 11:04:21 +0100 Original-Received: from localhost ([::1]:41953 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VgApY-0007ZV-4b for geb-bug-gnu-emacs@m.gmane.org; Tue, 12 Nov 2013 05:04:20 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:48766) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VgApO-0007YN-0l for bug-gnu-emacs@gnu.org; Tue, 12 Nov 2013 05:04:17 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1VgApG-0007na-M8 for bug-gnu-emacs@gnu.org; Tue, 12 Nov 2013 05:04:09 -0500 Original-Received: from debbugs.gnu.org ([140.186.70.43]:34106) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VgApG-0007nH-IA for bug-gnu-emacs@gnu.org; Tue, 12 Nov 2013 05:04:02 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.80) (envelope-from ) id 1VgApF-0006fD-Ts for bug-gnu-emacs@gnu.org; Tue, 12 Nov 2013 05:04:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Stephen Berman Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Tue, 12 Nov 2013 10:04:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 15841 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 15841-submit@debbugs.gnu.org id=B15841.138425063925605 (code B ref 15841); Tue, 12 Nov 2013 10:04:01 +0000 Original-Received: (at 15841) by debbugs.gnu.org; 12 Nov 2013 10:03:59 +0000 Original-Received: from localhost ([127.0.0.1]:48125 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1VgApC-0006ev-Os for submit@debbugs.gnu.org; Tue, 12 Nov 2013 05:03:59 -0500 Original-Received: from mout.gmx.net ([212.227.15.18]:62319) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1VgAp9-0006ee-EO for 15841@debbugs.gnu.org; Tue, 12 Nov 2013 05:03:56 -0500 Original-Received: from rosalinde.fritz.box ([89.245.100.165]) by mail.gmx.com (mrgmx003) with ESMTPSA (Nemesis) id 0LiTF6-1VA7rM30Zg-00cgIE for <15841@debbugs.gnu.org>; Tue, 12 Nov 2013 11:03:49 +0100 In-Reply-To: <877gceo3n9.fsf@rosalinde.fritz.box> (Stephen Berman's message of "Tue, 12 Nov 2013 01:38:34 +0100") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3.50 (gnu/linux) X-Provags-ID: V03:K0:BJL81Txdhv1P86QUMJ+g7WT3bWY2IPUquSyzYWcwg9r71s+NLP4 cPRAgOYyY57deOjq3ap6oxvAO5Nj3wgLYhl6AWiNzg8hTX+nzovRaVE7Eh83mjHtEts/y3Q Wm16ja3urLAo3IX4o6jjY9wbiVGzpH6zpcIXbOayeQGWLQmfsyKZiBoTQofg5XR642KZD9H vZxvkG8v0AyRohfo1t1qA== X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.15 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x X-Received-From: 140.186.70.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:80310 Archived-At: On Tue, 12 Nov 2013 01:38:34 +0100 Stephen Berman wrote: > On Mon, 11 Nov 2013 15:12:15 +0100 Stephen Berman wrote: > >> This change broke dired-maybe-insert-subdir. Perhaps this should be a >> new bug number, but since part of the breakage is display-related, I >> decided to report it here. To reproduce: >> >> 0. emacs -Q (built from trunk bzr 115033 or later) >> 1. Open a directory in Dired, e.g. the Emacs source tree root. >> 2. Put point on an entry listing a directory, e.g. admin. >> 3. Type `i'. >> => Emacs hangs. >> >> If I repeat the recipe but after step 1 type `M-: (setq cache-long-lines >> nil)', then at step 3, `i' works as expected. >> >> Here are more details of the breakage: >> >> Typing `C-g' releases the hang and shows the admin subdirectory, but its >> display is corrupted: (i) the "available" blocks information, which >> should appear at the end of the "total" line, instead appears to the >> right of the first entry `.' and is fontified with dired-directory face; >> (ii) while all the entries of admin are listed below the `..' entry, the >> entire line of each entry is fontified with dired-directory face, and >> these lines cannot be accessed by vertical motion commands like `C-n' or >> `C-p', though they can be with horizontal motion commands like `C-f' and >> `C-p'. In fact, all of these entries appear to Dired to be part of the >> line of the `..' entry, and AFACT this is what causes the hang: Emacs >> infloops in dired-move-to-filename because, when point appears to be at >> eof, beginning-of-line moves it back to the start of the `..' entry. > > I tracked the problematic fontification and motion behavior to > insert-directory in files.el: it happens during the loop when > decode-coding-region is called on the file names of the subdirectory > entries. I stepped through the code with Edebug but could not tell why > it goes wrong here, and I'm too tired to pursue it further now. Also, > when I step through this code, the "available" information is added at > the end of the entire subdirectory listing, unlike what I observed above > when just invoking `i' and then `C-g'. I guess this is due to the > interaction of redisplay with stepping through the code; it's still > clear that the subdirectory listing is being treated as part of the line > containing the `..' entry. I set a breakpoint on decode_coding_object and stepped through it after invoking `i', but the Dired display changed to show the problematic fontification only upon exiting decode_coding_object. I don't know how to find out when cache_long_scans is checked other than manually tracing the call chains of each subroutine of decode_coding_object, which is too laborious. Is it possible to have execution halt when cache_long_scans is checked, and if so, how? Or is there a better way to try to track down this bug? Steve Berman