On Tue, 27 Jun 2006 14:14:05 +0100, Pedro Côrte-Real <[EMAIL PROTECTED]> wrote:
> I'm trying to use libxml to run some XPath on a document I have as a > string in memory. This is my code for parsing the document: > > parser = XML::Parser.new > parser.string = self.content > @xmldoc = parser.parse > > Doing the same thing in a test script seems to work without > segfaulting. This is run inside a rails model and segfaults when > testing it. Here's the backtrace: > > 0xb72b37c4 in ruby_xml_parser_parse (self=144875496) at > ruby_xml_parser.c:1124 > 1124 xmlFreeDoc(rxpc->ctxt->myDoc); > > #0 0xb72b37c4 in ruby_xml_parser_parse (self=144875496) > at ruby_xml_parser.c:1124 > #1 0xb7ef050b in rb_iterator_p () from /usr/lib/libruby1.8.so.1.8 > #2 0xb7efaf8c in rb_thread_trap_eval () from /usr/lib/libruby1.8.so.1.8 > (...) > We have a few memory handling bugs that are still being ironed out, so it's possible you're seeing one of those. Hopefully soon we'll be able to release a fixed up version, but in the meantime you may (or may not) get more joy from the current CVS version. I'll try to reproduce this and take a look at it. Thanks, -- Ross Bamford - [EMAIL PROTECTED] _______________________________________________ libxml-devel mailing list [email protected] http://rubyforge.org/mailman/listinfo/libxml-devel
