1
0
Fork 0

Prevent from closing the simulator just because it can't write to the logger file

This commit is contained in:
Roman Ludwicki 2022-12-28 11:49:09 +01:00 committed by James Turner
parent 3667e5de3c
commit 56aa2cd479

View file

@ -41,9 +41,6 @@ FGLogger::init ()
if (!child->getBoolValue("enabled", false))
continue;
_logs.emplace_back(new Log());
Log &log = *_logs.back();
string filename = child->getStringValue("filename");
if (filename.empty()) {
filename = "fg_log.csv";
@ -66,9 +63,12 @@ FGLogger::init ()
"folder (" + (globals->get_fg_home() / "Export").utf8Str() + ").";
SG_LOG(SG_GENERAL, SG_ALERT, msg);
exit(EXIT_FAILURE);
return;
}
_logs.emplace_back(new Log());
Log &log = *_logs.back();
string delimiter = child->getStringValue("delimiter");
if (delimiter.empty()) {
delimiter = ",";