Avoid binary-in-DOCTYPE bug when parsing XML namespaces

So, the code now only attempts to extract the namespace for unknown XML
types, and even when it does the extraction, it's now wrapped in
ParseRunner to avoid the thread lock.