mirror of
https://github.com/keepassxreboot/keepassxc.git
synced 2024-10-01 01:26:01 -04:00
Release database before exiting CLI interactive mode
This commit is contained in:
parent
56a5a129c6
commit
dc42d5dda6
@ -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;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user