Re: [xml] xmlTextReaderExpand() always waits for next successor node
- From: Felix Geisendoerfer <felix debuggable com>
- To: veillard redhat com
- Cc: xml gnome org
- Subject: Re: [xml] xmlTextReaderExpand() always waits for next successor node
- Date: Mon, 19 Aug 2013 14:25:14 +0200
Hi Daniel,
I found some time to work on a patch, and came up with a
simple (4 lines added) solution to the problem, see attachement.
The patch passes all existing tests (make runtests), but I have not
created a new test for it yet. That being said, I'd be happy to create a
test if you're interested. Are there any tests already covering
xmlTextReaderExpand()? I couldn't find any.
Another question I have is whether or not I need to make sure
node->closed is set to 0 on node creation. I'm not familar with the
libxml alloc functions - do they zero out the memory they return?
About performance: I assume that this patch does not have significant
performance implications, but if you're worried about this, it would also
be possible to set the node->closed field in xmlTextReaderEndElement()
and xmlTextReaderEndElementNs() to avoid any overhead when not
using the text reader api.
Anyway, please let me know if you like the patch and if there is anything
I can do to make you consider merging it.
Cheers,
Felix
Attachment:
0001-xmlTextReaderExpand-Return-when-node-closes.patch
Description: Binary data
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]