MappingSet: Check that the line of a mapping file is valid before adding it

Fixes #7