diff options
author | George Hazan <ghazan@miranda.im> | 2018-04-11 20:55:08 +0300 |
---|---|---|
committer | George Hazan <ghazan@miranda.im> | 2018-04-11 20:55:08 +0300 |
commit | 21fe9b80ff4030f76f68a90726bc29e49627414c (patch) | |
tree | 0cc19b6970e3ee8db28d3ca2df677bbddd7f77c3 /src | |
parent | 18d675deb9ecad4cbd0aedda6e8a9de0db5a0700 (diff) |
check if this profile is already opened in another Miranda nevertheless if there's only one available profile or many
Diffstat (limited to 'src')
-rw-r--r-- | src/mir_app/src/database.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/mir_app/src/database.cpp b/src/mir_app/src/database.cpp index f0dbfa8077..2dc134e6da 100644 --- a/src/mir_app/src/database.cpp +++ b/src/mir_app/src/database.cpp @@ -487,6 +487,10 @@ int LoadDatabaseModule(void) return 1;
}
+ // if this profile is already opened in another miranda, silently return
+ if (FindMirandaForProfile(szProfile))
+ return 1;
+
// find a driver to support the given profile
bool retry;
int rc;
@@ -504,10 +508,6 @@ int LoadDatabaseModule(void) TranslateT("Miranda can't open that profile"), MB_OK | MB_ICONERROR);
}
else if (rc > 0) {
- // if there were drivers but they all failed cos the file is locked, try and find the miranda which locked it
- if (FindMirandaForProfile(szProfile))
- break;
-
if (fileExist(szProfile)) {
// file isn't locked, just no driver could open it.
MessageBox(nullptr,
|