Fix bug when reading bad-formed XMI files

Change-Id: I3eed0f0002a7ed50a4eb243cd049c461709ccb07
Reviewed-by: Sandro S. Andrade <sandroandrade@kde.org>