GNU bug report logs - #16449
24.3.50; emacs hangs while deleting comment in xml file with flyspell-mode on

Previous Next

Package: emacs;

Reported by: Levin Du <zslevin <at> gmail.com>

Date: Wed, 15 Jan 2014 03:21:02 UTC

Severity: normal

Tags: confirmed, fixed

Merged with 20995, 22319, 24253, 28040

Found in versions 24.3.50, 24.5, 25.1.50, 25.2

Fixed in version 26.1

Done: npostavs <at> users.sourceforge.net

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: Dmitry Antipov <dmantipov <at> yandex.ru>
To: 16449 <at> debbugs.gnu.org
Cc: Levin Du <zslevin <at> gmail.com>
Subject: bug#16449: 24.3.50; emacs hangs while deleting comment in xml file with flyspell-mode on
Date: Wed, 15 Jan 2014 18:58:47 +0400
On 01/15/2014 07:16 AM, Levin Du wrote:

> 1. Starting from `emacs -Q'
[...skip...]

Reproduced. Consider simpler example with the following XML:

<?xml version="1.0" encoding="UTF-8"?>
<tag0>
  <!--<tag1>Text</tag1>-->
</tag0>

Visit this file in nxml-mode and try to eval:

(goto-char (nxml-token-after))

from the beginning - you should advance token by token after
each evaluation, up to the end of buffer.

Next, remove comment, i.e. change the XML above to:

<?xml version="1.0" encoding="UTF-8"?>
<tag0>
  <tag1>Text</tag1>
</tag0>

Then try to advance from the beginning again. In my test, nxml-token-after
stops at '<' of '<tag1>' and never continues. Due to this, there is an
endless loop in  nxml-forward-single-balanced-item (lisp/nxml/nxml-mode.el):

 1627  (defun nxml-forward-single-balanced-item ()
 1628    (condition-case err
 1629        (goto-char (let ((end (nxml-token-after)))
 1630                     (save-excursion
 1631                       (while (eq xmltok-type 'space)   ; this is an
 1632                         (goto-char end)                ; endless
 1633                         (setq end (nxml-token-after))) ; loop

BTW, I have no ideas why C-g doesn't help.

Dmitry





This bug report was last modified 7 years and 342 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.