W3C home > Mailing lists > Public > xml-editor@w3.org > October to December 1999

Potential for ]]> inside element

From: Greg Hudson <ghudson@MIT.EDU>
Date: Mon, 15 Nov 1999 19:36:53 -0500 (EST)
Message-Id: <199911160036.TAA24891@small-gods.mit.edu>
To: xml-editor@w3.org
The intent of the CharData production is clearly to exclude ]]> from
being parseable as CharData and therefore as content:

	[14] CharData ::= [^<&]* - ([^<&]* ']]>' [^<&]*)

However, the string "]]>" is still parseable as content because
content can contain two adjacent CharData productions:

	[43] content ::= (element | CharData | Reference | CDSect | PI | Comment)*

So "]]>" could be parsed as content by parsing, say, "]" as one
CharData production, "]>" as a second, and then the two of those
productions together become a content production.

This breaks SGML compatibility, of course.  I don't have a fix.
Received on Monday, 15 November 1999 19:45:07 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Monday, 7 December 2009 10:59:30 GMT