diff options
author | George Hazan <george.hazan@gmail.com> | 2015-06-15 20:21:01 +0000 |
---|---|---|
committer | George Hazan <george.hazan@gmail.com> | 2015-06-15 20:21:01 +0000 |
commit | f4ea297307322013b3702231a5366b59f7257daa (patch) | |
tree | b1845e7358044e7c71fdf319c17aeb3a86c18da9 /src/mir_app | |
parent | f49b5e29d4f4bece4d7ae6b509f2ec523f89b319 (diff) |
more correct version of ProtoServiceExists
git-svn-id: http://svn.miranda-ng.org/main/trunk@14183 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'src/mir_app')
-rw-r--r-- | src/mir_app/src/protocols.cpp | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/src/mir_app/src/protocols.cpp b/src/mir_app/src/protocols.cpp index a61a45f930..dca0f5bed1 100644 --- a/src/mir_app/src/protocols.cpp +++ b/src/mir_app/src/protocols.cpp @@ -371,9 +371,12 @@ MIR_APP_DLL(int) ProtoServiceExists(const char *szModule, const char *szService) if (szModule == NULL || szService == NULL)
return false;
- TServiceListItem *item = (TServiceListItem*)bsearch(&szService, serviceItems, _countof(serviceItems), sizeof(serviceItems[0]), CompareServiceItems);
- if (item != NULL)
- return true;
+ PROTOACCOUNT *pa = Proto_GetAccount(szModule);
+ if (pa && !pa->bOldProto) {
+ TServiceListItem *item = (TServiceListItem*)bsearch(&szService, serviceItems, _countof(serviceItems), sizeof(serviceItems[0]), CompareServiceItems);
+ if (item != NULL)
+ return true;
+ }
char str[MAXMODULELABELLENGTH * 2];
strncpy_s(str, szModule, _TRUNCATE);
|