ASPN ActiveState Programmer Network
ActiveState
/ Home / Perl / PHP / Python / Tcl / XSLT /
/ Safari / My ASPN /
Cookbooks | Documentation | Mailing Lists | Modules | News Feeds | Products | User Groups


Recent Messages
List Archives
About the List
List Leaders
Subscription Options

View Subscriptions
Help

View by Topic
ActiveState
.NET Framework
Open Source
Perl
PHP
Python
Tcl
Web Services
XML & XSLT

View by Category
Database
General
SOAP
System Administration
Tools
User Interfaces
Web Programming
XML Programming


MyASPN >> Mail Archive >> perl-xml
perl-xml
XML::LibXML Catalogs problem
by Bruce Miller other posts by this author
Jun 18 2006 2:52AM messages near this date
view in the new Beta List Site
Re: XML::Twig beginner | Re: XML::LibXML Catalogs problem
& XSLT Hi all;
   As long as Petr is poking around in there... :> 

I've come across a curious bit with the XML_DEBUG_CATALOG
environment variable (which tells libxml2 to output
extra debugging info while resolving entities from catalogs).

The following code snippet works when the variable is
unset, but if you do 
  export XML_DEBUG_CATALOG=
before running it will do the apparent equivalent of die.
The message sounds almost as if it executed:
  die "found the entity!"
which seems to be overly enthusiastic :> 

I poked a little in LibXML.xs but can't figure out
what is going on other than something reportable
as an error has ended up in saved_error
(but I know next to nothing about xs)

======================
#!/usr/bin/perl -w
use XML::LibXML;

my $pubid ="-//OASIS//DTD DocBook XML V4.4//EN";
my $sysid = "docbookx.dtd";
XML::LibXML-> load_catalog('/etc/xml/catalog');
my $dtd = XML::LibXML::Dtd-> new($pubid,$sysid);
print "Got catalog: $dtd\n";

======================
-- 
bruce.miller@[...].gov
http://math.nist.gov/~BMiller/
_______________________________________________
Perl-XML mailing list
Perl-XML@[...].com
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs
Thread:
Bruce Miller
Petr Pajas
Bruce Miller

Privacy Policy | Email Opt-out | Feedback | Syndication
© ActiveState Software Inc. All rights reserved