I am having the same problem. I’ve searched for solutions and read the code in wp-admin/link-parse-opml.php, scratched my head, nothing works. I can’t even find this error code (invalid document end) in the php.net xml parsing error codes.
Glad to see it’s not just me.