Release database before exiting CLI interactive mode

This commit is contained in:
Balazs Gyurak authored and Jonathan White committed 2019-11-23 08:18:59 -05:00
1 parent 697f265249
commit 5c54dfe581
1 file changed
+2
+2
View File
@@ -149,6 +149,7 @@ void enterInteractiveMode(const QStringList& arguments)
prompt += "> ";
command = reader->readLine(prompt);
if (reader->isFinished()) {
currentDatabase->releaseData();
return;
}
@@ -162,6 +163,7 @@ void enterInteractiveMode(const QStringList& arguments)
errorTextStream << QObject::tr("Unknown command %1").arg(args[0]) << "\n";
continue;
} else if (cmd->name == "quit" || cmd->name == "exit") {
currentDatabase->releaseData();
return;
}