Issue #2393393 by mfernea, dragos.dumitrescu: getImportedXML fails with a fatal error if not dealing with a valid XML