So I don't see this as a bug in the libxml bindings.
Maybe you are right, but if I change XML::Document.file("test.xml")
to File.open("test.xml"), I won't run out of file handles.
I wonder what makes the difference...

Well, File.open is a ruby method while Document.open is a libxml method. Perhaps Ruby has some smarts built into it with File.open and the garbage collector.

Ruby does the same thing libxml now does, it calls the GC whenever errno is set to EMFILE or ENFILE.

And if I remember correctly, even the original test code with
libxml-ruby 3.8 did not run out of file handles on 32bit intel machines
either - the reported segfault only affected the amd64 (and maybe
other) architecture.

Interesting. Could be a difference in libxml, or maybe a difference in the bindings. Would have to check svn to know for sure.


I don't know why that would be... maybe on the other machine you had your limits set higher and the GC always kicked in. The test code uses sh -c `ulimit -n` to make sure that things run out of FDs. -sc

--
Sean Chittenden
[EMAIL PROTECTED]



_______________________________________________
libxml-devel mailing list
libxml-devel@rubyforge.org
http://rubyforge.org/mailman/listinfo/libxml-devel

Reply via email to