Are you sure it is the doc reference and not the GC finalizers running? Put a print statement after it and see what happens.
Dan On Feb 6, 2008, at 17:11, Saurabh Nanda wrote: > Why does the following code always cause a segfault on the last > statement, when simply trying to refer to 'doc'? The answer to this > could probably give me some pointers to my previous queries. > > require 'xml/libxml' > x=XML::Parser.string("<test>something</test>") > doc=x.parse > x.parse > puts '-- about to print refer to doc' > doc > > Thanks, > Saurabh. > -- > http://nandz.blogspot.com > http://foodieforlife.blogspot.com > _______________________________________________ > libxml-devel mailing list > libxml-devel@rubyforge.org > http://rubyforge.org/mailman/listinfo/libxml-devel _______________________________________________ libxml-devel mailing list libxml-devel@rubyforge.org http://rubyforge.org/mailman/listinfo/libxml-devel