shared: FileScanWorker: Catch LooqsGeneralException for better error msgs

Este commit está contenido en:
Albert S. 2023-04-02 21:41:01 +02:00
padre 44b9986166
commit a3cfb7ade1
Se han modificado 1 ficheros con 8 adiciones y 1 borrados

Ver fichero

@ -21,11 +21,18 @@ void FileScanWorker::run()
{
sfr = saver.addFile(path);
}
catch(LooqsGeneralException &e)
{
Logger::error() << e.message << Qt::endl;
sfr = PROCESSFAIL;
}
catch(std::exception &e)
{
Logger::error() << e.what();
Logger::error() << e.what() << Qt::endl;
sfr = PROCESSFAIL; // well...
}
emit result({path, sfr});
if(stopToken->load(std::memory_order_relaxed)) // TODO: relaxed should suffice here, but recheck
{