Alexey,

For question 1):

If a DTD is specified, the parser will always scan it even if the
validation is off, because DTDs can provide many other information, like
default attributes and entities, in addition to validation.  So the
parser behaviour is correct.

For quesiton 2):

Someone has reported a similar problem earlier, and I think this is a
bug.  With empty DOCTYPE declaration (<!DOCTYPE rootnodename>) and
ValSchemes::Val_Auto, the fHaveSubset should be false and validation
should be off.  I have a fix ready, and should be checked in within the
next few days.

Thanks!

Tinny



Alexey Miroshnichenko wrote:

> Hi all,
>
>   Pardon me if I address my problem not correctly. But may be anyone
>   can help my with follow questions. I use xerces-c-1_3_0.
>
>   1) I have well-formed xml file with DOCTYPE declaration but
>   corresponding dtd file is absent. I do
>
>     setValidationScheme(SAXParser::ValSchemes::Val_Never)
>
>   and I suppose that dtd file do not needed in this case. But I catch
>   exception: unnable open dtd file.
>   I looked in source. At first we scan dtd file(XMLScanner.cpp,
>   scanProlog()), then we set up Validation scheme(XMLScanner.cpp,
>   scanDocument()).
>
>   Is this behaviour of parser engine correct?
>
>   2) I have well-formed xml file with empty DOCTYPE declaration
>   <!DOCTYPE rootnodename> and I set ValSchemes::Val_Auto. After
>   successful scanDTD() we set fHaveSubset = true. And after this
>   we set fValidate = fHaveSubset, i.e. "true". The same place in
>   XMLScanner.cpp. So, validation failed.
>
>   The same question.
>
>   May be I should go to bugzilla?
>
>   Thanks before.
>
> --
> Best regards,
>  Alexey                          mailto:[EMAIL PROTECTED]
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to