mirror of
https://github.com/keepassxreboot/keepassxc.git
synced 2025-08-22 04:49:42 -04:00
Deactivate read-only mode for now. Fixes #803.
Read-only mode isn't in a good state and is triggering bugs. We'll come up with a good design for read-only mode at a later time.
This commit is contained in:
parent
49487f9d4a
commit
d5de042529
1 changed files with 8 additions and 5 deletions
|
@ -120,11 +120,14 @@ bool Database::open(const QString& filePath, QSharedPointer<const CompositeKey>
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!readOnly && !dbFile.open(QIODevice::ReadWrite)) {
|
// Don't autodetect read-only mode, as it triggers an upstream bug.
|
||||||
readOnly = true;
|
// See https://github.com/keepassxreboot/keepassxc/issues/803
|
||||||
}
|
// if (!readOnly && !dbFile.open(QIODevice::ReadWrite)) {
|
||||||
|
// readOnly = true;
|
||||||
if (!dbFile.isOpen() && !dbFile.open(QIODevice::ReadOnly)) {
|
// }
|
||||||
|
//
|
||||||
|
// if (!dbFile.isOpen() && !dbFile.open(QIODevice::ReadOnly)) {
|
||||||
|
if (!dbFile.open(QIODevice::ReadOnly)) {
|
||||||
if (error) {
|
if (error) {
|
||||||
*error = tr("Unable to open file %1.").arg(filePath);
|
*error = tr("Unable to open file %1.").arg(filePath);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue