xmerl_scan {validation, true}
Bertil Karlsson
bertil@REDACTED
Mon May 2 16:55:33 CEST 2005
The content of the fix is as follows:
diff xmerl_scan.erl@@/main/xmerl/90 xmerl_scan.erl@@/main/xmerl/89
2785,2790d2784
< scan_nmtoken("%"++T, S0=#xmerl_scanner{environment={external,_}}) ->
< ?bump_col(1),
< {PERefName, T1, S1} = scan_pe_reference(T, S),
< ExpRef = expand_pe_reference(PERefName, S1,as_PE),
< {_,T2,S2} = strip(ExpRef ++ T1,S1),
< scan_nmtoken(T2,S2);
/Bertil
Bertil Karlsson wrote:
> This was a bug in xmerl, that now is corrected and probably will be part
> of the next open source release.
> /Bertil
>
> Michael McDaniel wrote:
>
>> using this DTD...
>> ---------------------
>> <?xml version="1.0" encoding="UTF-8"?>
>>
>> <!ENTITY % listings "Rup | Bog | BoR">
>>
>> <!ATTLIST test
>> testListings (%listings;) #REQUIRED
>>
>> ---------------------
>>
>> results in
>> (m1@REDACTED)90> xmerl_scan:file("test.xml",
>> [{validation,true}, {doctype_DTD, "foo.dtd"}]).
>> 2775- fatal: {invalid_nmtoken,"%listi"}
>> ** exited: {fatal,{{invalid_nmtoken,"%listi"},"./foo.dtd",7,20}} **
>>
>>
>> although using this one works...
>> ---------------------
>> <?xml version="1.0" encoding="UTF-8"?>
>>
>> <!ATTLIST test
>> testListings (Rup | Bog | BoR) #REQUIRED
>>
>> ---------------------
>>
>>
>> QUESTION: 1) is something incorrect with the first DTD or is it a bug
>> in xmerl_scan using validation?
>>
>>
>> thanks,
>>
>> ~Michael
>>
>>
>
>
More information about the erlang-questions
mailing list