mirror of
https://github.com/keepassxreboot/keepassxc.git
synced 2025-12-04 15:39:34 +01:00
Handling entry not found.
This commit is contained in:
committed by
Louis-Bertrand Varin
parent
15c2727a1d
commit
db1bf88934
@@ -78,6 +78,11 @@ int Show::execute(int argc, char **argv)
|
|||||||
|
|
||||||
Uuid uuid = Uuid::fromHex(args.at(1));
|
Uuid uuid = Uuid::fromHex(args.at(1));
|
||||||
Entry* entry = db->resolveEntry(uuid);
|
Entry* entry = db->resolveEntry(uuid);
|
||||||
|
if (entry == nullptr) {
|
||||||
|
qCritical("No entry found with uuid %s", qPrintable(uuid.toHex()));
|
||||||
|
return EXIT_FAILURE;
|
||||||
|
}
|
||||||
|
|
||||||
out << entry->password() << "\n";
|
out << entry->password() << "\n";
|
||||||
return EXIT_SUCCESS;
|
return EXIT_SUCCESS;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user