jst convinced me that we should add the %foo; part into the internal subset as well. If save as complete wants to tweak that, then it's their business. We need to change Expat a little so that when it calls nsExpatDriver::HandleExternalEntityRef() we get the name, and then in that same method (?) append to mDoctypeText.
Comment on attachment 113229 [details] [diff] [review] Possible fix r=harishd
Was checked in with the fix to bug 191327.