A `<metadata>` element without a `type` attribute makes
`get_attribute()` return nullptr, which was then assigned to a
`std::string` and read as a C string.
Check it the way the sibling metadata handler already does, and stop the
parse.
Regression test in `tests/libslic3r/test_amf.cpp`, a new file: the suite
had no AMF test at all.