[Date Prev][Date Next] [Thread Prev][Thread Next]
[Thread Index]
[Date Index]
[Author Index]
Re: [xml] Entity with elements inside it?
- From: Bo Yang <struggleyb nku gmail com>
- To: veillard redhat com
- Cc: xml gnome org
- Subject: Re: [xml] Entity with elements inside it?
- Date: Fri, 10 Jul 2009 23:23:21 +0800
On Fri, Jul 10, 2009 at 9:13 PM, Daniel Veillard<veillard redhat com> wrote:
> On Fri, Jul 10, 2009 at 08:35:42PM +0800, Bo Yang wrote:
>> On Fri, Jul 10, 2009 at 3:44 PM, Daniel Veillard<veillard redhat com> wrote:
>> > On Fri, Jul 10, 2009 at 10:01:06AM +0800, Bo Yang wrote:
>> >> > MiLu FLUNDER:~/win-dev/XML > xmllint --noent nstoken.xml
>> >> > <?xml version="1.0"?>
>> >> > <!DOCTYPE Urmel [
>> >> > <!ENTITY jaja "<eins><zwei/><drei>drei</drei></eins>">
>> >> > ]>
>> >> > <Urmel> <eins><zwei/><drei>drei</drei></eins> </Urmel>
>> But what I got is:
>>
>> (gdb) p *child
>> $8 = {_private = 0x0, type = XML_ENTITY_REF_NODE, name = 0x9f83d20
>> "ent4", children = 0x9f7d210, last = 0x9f7d210,
>> parent = 0x9f83ad0, next = 0x0, prev = 0x9f83ff0, doc = 0x9f7b450, ns = 0x0,
>> content = 0x9f7d260 "<entElement domestic='Yes'>Element
>> data</entElement><?PItarget PIdata?>", properties = 0x0,
>> nsDef = 0x0, psvi = 0x0, line = 0, extra = 0}
>> (gdb) p *child->children
>> $9 = {_private = 0x0, type = XML_ENTITY_DECL, name = 0x9f7b086 "ent4",
>> children = 0x0, last = 0x0, parent = 0x9f7b5a0,
>> next = 0x9f7d2b0, prev = 0x9f7b740, doc = 0x9f7b450, ns = 0x9f7d078,
>> content = 0x9f7d260 "<entElement domestic='Yes'>Element
>> data</entElement><?PItarget PIdata?>", properties = 0x47,
>> nsDef = 0x1, psvi = 0x0, line = 0, extra = 0}
>> (gdb)
>
> Clearly not the same document.
Yes, it is not the same element, but the key point here is that, in
your debugger, the entity_decl node under the entity_ref node has
children which are parsed from the entity string, but in my system,
there is no.
>
>> I use libxml2.6.26 and libxml2.6.31, which version do you use? And my
>
> latest version from git , 2.7.3 based, I ran gdb on xmllint --shell
I use the latest version from the Git, but I still get my above
result. I mean, the entity_ref node has a entity_decl node but the
later has no children at all. I don't know why?
Regards!
Bo
[Date Prev][Date Next] [Thread Prev][Thread Next]
[Thread Index]
[Date Index]
[Author Index]