XML::LibXML - vaidation problem
by Petr Pajas other posts by this author
Oct 2 2002 8:01AM messages near this date
view in the new Beta List Site
Re: Continuing Perl 5.8.0 Problems
|
Re: XML::LibXML - vaidation problem
Hi All,
I'm experiencing a strange problem. While the following piece of XML
passes through 'xmllint --valid' without problems it makes XML::LibXML
SIGSEGV during validation. On the other hand, almost all other XML
files with a DTD I have validate without problems. Is the problem
related to my configuration only or can also somebody else reproduce
it?
The XML:
<?xml version='1.0'?>
<!DOCTYPE test [
<!ELEMENT test (#PCDATA)>
]>
<test>
</test>
My configuration:
RH 7.2/7.3
perl 5.6.1
XML-LibXML 1.52/1.53/CVS
libxml-2.4.21/libxml-2.4.23
Here is a short test code:
#!/usr/bin/perl
use XML::LibXML;
my $parser=XML::LibXML-> new();
$parser-> validation(1);
my $doc=$parser-> parse_string(<<'EOF');
<?xml version='1.0'?>
<!DOCTYPE test [
<!ELEMENT test (#PCDATA)>
]>
<test>
</test>
EOF
print STDERR "parsed\n"; # ok (even with validating parser)
print STDERR "validate: ",$doc-> validate(),"\n"; # SIGSEGV
print STDERR "valid: ",$doc-> is_valid(),"\n"; # would SIGSEGV too
print STDERR "done\n"; # no way!
__END__
Thanks,
-- Petr
_______________________________________________
Perl-XML mailing list
Perl-XML@[...].com
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs
Thread:
Petr Pajas
Christian Glahn
|