diff options
author | George Hazan <ghazan@miranda.im> | 2018-11-26 15:23:19 +0300 |
---|---|---|
committer | George Hazan <ghazan@miranda.im> | 2018-11-26 15:23:19 +0300 |
commit | da1b2a070c113222cbbad31b18ab704c7d1301b2 (patch) | |
tree | 841092328c9c7fb35c3454627296862a956f5d5c /protocols/MSN | |
parent | be1918c1b2986ddb387cd593deddf120f9e61874 (diff) |
Chat_AddGroup - simplified prototype
Diffstat (limited to 'protocols/MSN')
-rw-r--r-- | protocols/MSN/src/msn_chat.cpp | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/protocols/MSN/src/msn_chat.cpp b/protocols/MSN/src/msn_chat.cpp index 7405e4a4b3..200cdc4b27 100644 --- a/protocols/MSN/src/msn_chat.cpp +++ b/protocols/MSN/src/msn_chat.cpp @@ -58,10 +58,13 @@ int CMsnProto::MSN_ChatInit(GCThreadData *info, const char *pszID, const char *p wcsncpy(szName, _A2T(pszTopic), _countof(szName));
else mir_snwprintf(szName, L"%s %s%d",
m_tszUserName, TranslateT("Chat #"), m_chatID);
- Chat_NewSession(GCW_CHATROOM, m_szModuleName, info->mChatID, szName);
+
+ SESSION_INFO *si = Chat_NewSession(GCW_CHATROOM, m_szModuleName, info->mChatID, szName);
+ if (!si)
+ return 1;
for (auto &it : m_ptszRoles)
- Chat_AddGroup(m_szModuleName, info->mChatID, TranslateW(it));
+ Chat_AddGroup(si, TranslateW(it));
Chat_Control(m_szModuleName, info->mChatID, SESSION_INITDONE);
Chat_Control(m_szModuleName, info->mChatID, SESSION_ONLINE);
|