I've been sitting on this for awhile due to the propagated input clean up needed for libxml2, but it needn't block this patch.