Reported by cppcheck: fix a memory leak
This commit is contained in:
parent
95a5326c4e
commit
687be04678
1 changed files with 1 additions and 0 deletions
|
@ -83,6 +83,7 @@ FGModelMgr::add_model (SGPropertyNode * node)
|
|||
} catch (const sg_throwable& t) {
|
||||
SG_LOG(SG_GENERAL, SG_ALERT, "Error loading " << path << ":\n "
|
||||
<< t.getFormattedMessage() << t.getOrigin());
|
||||
delete instance;
|
||||
return;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue