emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Emacs-diffs] /srv/bzr/emacs/emacs-24 r107886: Fix xml.el regression int


From: Chong Yidong
Subject: [Emacs-diffs] /srv/bzr/emacs/emacs-24 r107886: Fix xml.el regression introduced by 2012-01-27 change.
Date: Sat, 21 Apr 2012 17:53:37 +0800
User-agent: Bazaar (2.3.1)

------------------------------------------------------------
revno: 107886
fixes bug(s): http://debbugs.gnu.org/11286
committer: Chong Yidong <address@hidden>
branch nick: emacs-24
timestamp: Sat 2012-04-21 17:53:37 +0800
message:
  Fix xml.el regression introduced by 2012-01-27 change.
  
  * lisp/xml.el (xml-parse-region, xml-parse-tag): Avoid errors due to
  reaching eob.
modified:
  lisp/ChangeLog
  lisp/xml.el
=== modified file 'lisp/ChangeLog'
--- a/lisp/ChangeLog    2012-04-20 19:17:59 +0000
+++ b/lisp/ChangeLog    2012-04-21 09:53:37 +0000
@@ -1,3 +1,8 @@
+2012-04-21  Chong Yidong  <address@hidden>
+
+       * xml.el (xml-parse-region, xml-parse-tag): Avoid errors due to
+       reaching eob (Bug#11286).
+
 2012-04-20  Richard Stallman  <address@hidden>
 
        Fix logic for returning to and yanking from Rmail buffer.

=== modified file 'lisp/xml.el'
--- a/lisp/xml.el       2012-01-27 08:46:10 +0000
+++ b/lisp/xml.el       2012-04-21 09:53:37 +0000
@@ -323,7 +323,8 @@
                  (cond
                   ((null result)
                    ;; Not looking at an xml start tag.
-                   (forward-char 1))
+                   (unless (eobp)
+                     (forward-char 1)))
                   ((and xml (not xml-sub-parser))
                    ;; Translation of rule [1] of XML specifications
                    (error "XML: (Not Well-Formed) Only one root tag allowed"))
@@ -422,7 +423,8 @@
      ((looking-at "<!--")
       (search-forward "-->")
       (skip-syntax-forward " ")
-      (xml-parse-tag parse-dtd xml-ns))
+      (unless (eobp)
+       (xml-parse-tag parse-dtd xml-ns)))
      ;;  end tag
      ((looking-at "</")
       '())


reply via email to

[Prev in Thread] Current Thread [Next in Thread]