[xml] xmlKeepBlanksDefault doesn't seem to work
- From: Timothy Flechtner <Timothy Flechtner tellabs com>
- To: xml gnome org
- Cc: veillard redhat com
- Subject: [xml] xmlKeepBlanksDefault doesn't seem to work
- Date: Wed, 09 May 2001 16:32:03 -0500
hi everybody,
either i don't understand what's supposed to happen, or something's
wrong with my setup, but i just upgraded from libxml1 to libxml2
(details below), and i can't get it to behave the way it did in the
"good old days". :)
given the xml file "schema_ADM.xml":
<?xml version="1.0" standalone="yes"?>
<category name="ADM" elem_def_name="Object" elem_name="instance"
db_format="OOA">
<data_type_list>
<data_type name="integer"><scalar_type
default_value="0"><unbound_type
editor_type="int32"></unbound_type></scalar_type></data_type>
</data_type_list>
</category>
i ran xmllint --debug schema_ADM.xml and got:
DOCUMENT
version=1.0
URL=schema_ADM.xml
standalone=true
ELEMENT category
ATTRIBUTE name
TEXT
content=ADM
ATTRIBUTE elem_def_name
TEXT
content=Object
ATTRIBUTE elem_name
TEXT
content=instance
ATTRIBUTE db_format
TEXT
content=OOA
TEXT
content=
ELEMENT data_type_list
TEXT
content=
ELEMENT data_type
ATTRIBUTE name
TEXT
content=integer
ELEMENT scalar_type
ATTRIBUTE default_value
TEXT
content=0
ELEMENT unbound_type
ATTRIBUTE editor_type
TEXT
content=int32
TEXT
content=
TEXT
content=
i then ran xmllint --debug --noblanks and got the exact same thing. my
understanding was that all those TEXT nodes wouldn't be created in the
noblanks case. i tried setting xmlKeepBlanksDefault(0) in my own code
(and then i set it to 1, just to try both cases), and it behaves the
same way as xmllint. could someone either show me the error of my ways
(if i'm wrong about what should happen) or suggest a way to fix whats
wrong (if i'm not)?
my system is configured like so:
bash-2.03$ uname -a
SunOS sunbc558 5.6 Generic_105181-11 sun4u sparc SUNW,Ultra-5_10
bash-2.03$ xml-config --version
1.8.10
bash-2.03$ xml2-config --version
2.3.8
bash-2.03$ xml-config --version
1.8.10
bash-2.03$ xml++-config --version
0.12
thanks!
-tim
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]