GNU bug report logs - #16344
24.3; xml-parse-region stuck on specific input, uses lots of memory

Previous Next

Package: emacs;

Reported by: Christopher Wellons <wellons <at> nullprogram.com>

Date: Sat, 4 Jan 2014 23:40:02 UTC

Severity: normal

Found in version 24.3

Done: Ulf Jasper <ulf.jasper <at> web.de>

Bug is archived. No further changes may be made.

To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 16344 in the body.
You can then email your comments to 16344 AT debbugs.gnu.org in the normal way.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to bug-gnu-emacs <at> gnu.org:
bug#16344; Package emacs. (Sat, 04 Jan 2014 23:40:02 GMT) Full text and rfc822 format available.

Acknowledgement sent to Christopher Wellons <wellons <at> nullprogram.com>:
New bug report received and forwarded. Copy sent to bug-gnu-emacs <at> gnu.org. (Sat, 04 Jan 2014 23:40:03 GMT) Full text and rfc822 format available.

Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Christopher Wellons <wellons <at> nullprogram.com>
To: bug-gnu-emacs <at> gnu.org
Subject: 24.3; xml-parse-region stuck on specific input, uses lots of memory
Date: Sat, 04 Jan 2014 18:39:30 -0500
The function `xml-parse-region' is never returning from parsing this
specific input. It's saturing a CPU core while using huge quantities of
memory. Fortunately it can be aborted with C-g.

    (with-temp-buffer
      (insert "<!----><x>< /x>")
      (xml-parse-region))

The trigger is a comment followed by at least one opening tag followed
by a stray less-than character. This is not valid XML due to that extra
space in the closing tag, but I'm expecting `xml-parse-region' to signal
an error in the case of invalid input rather than lock up Emacs.

Just for the sake of context, this issue was initially discovered here:

https://github.com/skeeto/elfeed/issues/17




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#16344; Package emacs. (Wed, 02 Mar 2016 18:12:02 GMT) Full text and rfc822 format available.

Message #8 received at 16344 <at> debbugs.gnu.org (full text, mbox):

From: Ulf Jasper <ulf.jasper <at> web.de>
To: Christopher Wellons <wellons <at> nullprogram.com>
Cc: 16344 <at> debbugs.gnu.org, 16344-done <at> debbugs.gnu.org
Subject: Re: bug#16344: 24.3;
 xml-parse-region stuck on specific input, uses lots of memory
Date: Wed, 02 Mar 2016 19:11:03 +0100
Fixed in branch emacs-25.

xml-parser will throw an error now.





Reply sent to Ulf Jasper <ulf.jasper <at> web.de>:
You have taken responsibility. (Wed, 02 Mar 2016 18:12:02 GMT) Full text and rfc822 format available.

Notification sent to Christopher Wellons <wellons <at> nullprogram.com>:
bug acknowledged by developer. (Wed, 02 Mar 2016 18:12:03 GMT) Full text and rfc822 format available.

bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Thu, 31 Mar 2016 11:24:04 GMT) Full text and rfc822 format available.

This bug report was last modified 9 years and 87 days ago.

Previous Next


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