1
0
mirror of https://github.com/gnss-sdr/gnss-sdr synced 2024-12-14 04:00:34 +00:00

Be more explicit in the terminal if an instantiation fails

This commit is contained in:
Carles Fernandez 2021-09-24 09:20:49 +02:00
parent 9384c8c303
commit dcf9c8c774
No known key found for this signature in database
GPG Key ID: 4C583C52B0C3877D

View File

@ -1273,8 +1273,10 @@ std::unique_ptr<GNSSBlockInterface> GNSSBlockFactory::GetBlock(
}
catch (const std::exception& e)
{
std::cout << "Configuration error. GNSS-SDR program ended.\n";
LOG(INFO) << "Exception raised while instantiating a block: " << e.what();
LOG(INFO) << "Exception raised while instantiating the block: " << e.what();
std::cout << "Configuration error in " << role << " block, implementation " << (implementation == "Wrong"s ? "not defined."s : implementation) << ". The error was:\n"
<< e.what() << '\n';
std::cout << "GNSS-SDR program ended.\n";
exit(1);
}
return block;