Commit 12a45daa authored by Hugo Beauzée-Luyssen's avatar Hugo Beauzée-Luyssen
Browse files

MetadataParser: Ensure we have a media to analyze

parent 74d33606
......@@ -141,6 +141,15 @@ parser::Task::Status MetadataParser::run( parser::Task& task )
alreadyInParser = true;
else if ( == nullptr )
// If we have a file but no media, this is a problem, we can analyze as
// much as we want, but won't be able to store anything.
// Keep in mind that if we are in this code path, we are not analyzing
// a playlist.
assert( false );
return parser::Task::Status::Fatal;
if ( task.parentPlaylist != nullptr )
task.parentPlaylist->add(>id(), task.parentPlaylistIndex );
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment