summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMike Kaganski <mike.kaganski@collabora.com>2016-10-15 00:26:09 +1000
committerMike Kaganski <mike.kaganski@collabora.com>2016-10-14 14:48:09 +0000
commitc3fa866e768b67650b1e52308565e9344db0b4b4 (patch)
tree58042f66187be8ec322a52a2a8deacc4052a386b
parent0b7e11a2a7ade0b565c18d1deb58c19848f6ceef (diff)
tdf#92817: re-implement empty lockfile fix
As stated in original commit 8d411a4a1ef6844c00bc714f8b144d3729e4f4e8, An empty lock file doesn't have OOOUSERNAME and SYSUSERNAME. Change-Id: I17fc6d3375f411749fcbbe80535beb8ba53a0e71 Reviewed-on: https://gerrit.libreoffice.org/29834 Reviewed-by: Michael Meeks <michael.meeks@collabora.com> Tested-by: Michael Meeks <michael.meeks@collabora.com>
-rw-r--r--sfx2/source/doc/docfile.cxx6
1 files changed, 2 insertions, 4 deletions
diff --git a/sfx2/source/doc/docfile.cxx b/sfx2/source/doc/docfile.cxx
index e93e95407773..2179f8248284 100644
--- a/sfx2/source/doc/docfile.cxx
+++ b/sfx2/source/doc/docfile.cxx
@@ -838,10 +838,8 @@ SfxMedium::ShowLockResult SfxMedium::ShowLockedDocumentDialog( const LockFileEnt
{
ShowLockResult nResult = ShowLockResult::NoLock;
- if( aData[LockFileComponent::OOOUSERNAME] == aData[LockFileComponent::SYSUSERNAME] ||
- aData[LockFileComponent::OOOUSERNAME].isEmpty() ||
- aData[LockFileComponent::SYSUSERNAME].isEmpty()
- )
+ // tdf#92817: Simple check for empty lock file that needs to be deleted
+ if( aData[LockFileComponent::OOOUSERNAME].isEmpty() && aData[LockFileComponent::SYSUSERNAME].isEmpty() )
bOwnLock=true;
// show the interaction regarding the document opening