Commit cb760e95 authored by Hugo Beauzée-Luyssen's avatar Hugo Beauzée-Luyssen

Parser: Don't assume there is at least one metadata service

parent e306bf56
......@@ -35,6 +35,8 @@ void Parser::parse(FilePtr file, IMetadataCb* cb)
{
std::lock_guard<std::mutex> lock( m_lock );
if ( m_services.size() == 0 )
return;
m_tasks.push_back( new Task( file, m_services, cb ) );
if ( m_thread == nullptr )
m_thread.reset( new std::thread( &Parser::run, this ) );
......
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