sparklemotion/nokogiri — pull request #805 by lcdhoffman (2012-12-04 01:43:58+00:00)
Title: Fix EmptyStackException thrown by nokogiri-java when an xlink:href attribute shows up with an empty XmlBaseStack

This is a revision of the PR posted by @bilts

https://github.com/sparklemotion/nokogiri/pull/534

The test now appears to pass in both MRI 1.9.3 and jruby-head 1.9.2. The assumption is:

If a node has an xml:base or inherits one, the xlink:href will not affect the node's xml base.

If the node doesn't have an xml:base or inherit one, AND the xlink:href attribute begins with 'http://', the xlink:href will set the node's xml base.