Segfault when assigning DocumentFragment.children to Document.root #1900
Describe the bug
I was playing around with nokogiri, and managed to segfault it by assigning
require 'nokogiri' a = Nokogiri::XML::Document.new b = Nokogiri::XML::DocumentFragment.new a a.root = b.children
It should fail with an argument error like all other types passed into it do.
In the unlikely event it matters, I'm running through
The text was updated successfully, but these errors were encountered:
Note that the JRuby implementation does the right thing by raising an exception; we need to do the same in the CRuby implementation. Alternatively, we should have a Ruby wrapper for the extension implementation that does this type check consistently across both. Targetting v1.11.0.