Improved XML error message