Bug 7007 - WFC Entity Declared and standalone documents
: WFC Entity Declared and standalone documents
Status: RESOLVED FIXED
Product: Validator
Parser
: HEAD
: PC Windows XP
: P2 normal (vote)
: 0.8.6
Assigned To: This bug has no owner yet - up for the taking
: qa-dev tracking
:
:
:
:
:
  Show dependency treegraph
 
Reported: 2009-06-09 14:40 UTC by Giovanni Campagna
Modified: 2010-03-02 18:58 UTC (History)
0 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Giovanni Campagna 2009-06-09 14:40:40 UTC
While validating an XML document, the violation of WFC Entity Declared (
http://www.w3.org/TR/xml/#wf-entdeclared ) is not reported if the entity is
declared in the external subset, even if the document is declared as
"standalone=yes".

An example of this behaviour:

<?xml version="1.0" encoding="uft-8" standalone="yes"?>
<!DOCTYPE test SYSTEM "http://example.org/test.dtd"><test>&test;</test>

where test.dtd contains:
<!ENTITY test "test content">
<!ELEMENT test (#PCDATA)*>

is considered valid by the markup validator, but it should be a Fatal Error
according to XML, because the document is not well-formed (and thus cannot be
valid).

(Tested using the version online at validator.w3.org)
Comment 1 Ville Skytt 2009-12-14 21:22:17 UTC
All undefined entity errors from XML::LibXML were explicitly filtered out to
avoid noise because the XML::LibXML preprocessor does not currently load
external DTDs in any case; the development version no longer filters them out
for standalone documents.
Comment 2 Ville Skytt 2010-03-02 18:58:57 UTC
Fix included in 0.8.6.