From 10caef48b10d57acb7da8d7195cc43642305045e Mon Sep 17 00:00:00 2001 From: Richard Harrison Date: Wed, 7 Mar 2018 03:09:38 +0100 Subject: [PATCH] Change YASim solution failure message to display as an alert; but not to call exit(). It is the call to exit that causes FG to lock up and become a zombie. Alternative is to throw an exception, i.e.: throw sg_error(std::string("YASim SOLUTION FAILURE:") + a->getFailureMsg();); --- src/FDM/YASim/YASim.cxx | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/FDM/YASim/YASim.cxx b/src/FDM/YASim/YASim.cxx index cfdf70d3f..3d168566e 100644 --- a/src/FDM/YASim/YASim.cxx +++ b/src/FDM/YASim/YASim.cxx @@ -77,9 +77,8 @@ void YASim::report() SG_LOG(SG_FLIGHT, SG_INFO, buf); if(a->getFailureMsg()) { - SG_LOG(SG_FLIGHT, SG_ALERT, "YASim SOLUTION FAILURE:"); - SG_LOG(SG_FLIGHT, SG_ALERT, a->getFailureMsg()); - exit(1); + SG_LOG(SG_FLIGHT, SG_POPUP, std::string("YASim flight dynamics problem:") + a->getFailureMsg()+"\nThe aircraft may not fly correctly"); + //throw sg_error(std::string("YASim SOLUTION FAILURE:") + a->getFailureMsg();); } }