diff options
author | George Hazan <ghazan@miranda.im> | 2018-10-17 18:22:55 +0300 |
---|---|---|
committer | George Hazan <ghazan@miranda.im> | 2018-10-17 18:22:55 +0300 |
commit | 55bc7336d19d39861d57fd8fc1923a28cd300247 (patch) | |
tree | c214f11659aeb1566377e3537c41e539bc377139 /src/mir_app | |
parent | 2a24763dc13f729f41f6909d9e74e9bc7d6243a8 (diff) |
fix for sorting sessions, cause SESSION_INFO is now a class
Diffstat (limited to 'src/mir_app')
-rw-r--r-- | src/mir_app/src/chat_manager.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/mir_app/src/chat_manager.cpp b/src/mir_app/src/chat_manager.cpp index c4566909df..4ef7c5f523 100644 --- a/src/mir_app/src/chat_manager.cpp +++ b/src/mir_app/src/chat_manager.cpp @@ -159,12 +159,12 @@ SESSION_INFO* SM_FindSession(const wchar_t *pszID, const char *pszModule) if (!pszID || !pszModule)
return nullptr;
- SESSION_INFO tmp;
- tmp.pszModule = (char*)pszModule;
- tmp.ptszID = (wchar_t*)pszID;
+ SESSION_INFO *tmp = (SESSION_INFO*)alloca(sizeof(SESSION_INFO));
+ tmp->pszModule = (char*)pszModule;
+ tmp->ptszID = (wchar_t*)pszID;
mir_cslock lck(csChat);
- return g_arSessions.find(&tmp);
+ return g_arSessions.find(tmp);
}
BOOL SM_SetOffline(const char *pszModule, SESSION_INFO *si)
|