# HG changeset patch # User Chong Yidong # Date 1223233313 0 # Node ID 2a05b2390d45668c608ade84e8b5c4b0f00d7c70 # Parent 26654d8c83db73d4814d0572c8e5f5bd5bdd55f4 (xml-parse-string): Use skip-chars-forward. diff -r 26654d8c83db -r 2a05b2390d45 lisp/xml.el --- a/lisp/xml.el Sun Oct 05 19:01:45 2008 +0000 +++ b/lisp/xml.el Sun Oct 05 19:01:53 2008 +0000 @@ -494,9 +494,7 @@ (defun xml-parse-string () "Parse the next whatever. Could be a string, or an element." (let* ((pos (point)) - (string (progn (if (search-forward "<" nil t) - (forward-char -1) - (goto-char (point-max))) + (string (progn (skip-chars-forward "^<") (buffer-substring-no-properties pos (point))))) ;; Clean up the string. As per XML specifications, the XML ;; processor should always pass the whole string to the