Ensures that DTDs do not cause resources to be downloaded

(Backport of #1622/dc94b94 from master)
Merge pull request #1631 from richdougherty/xml-io

Unnecessary XML DTD downloads