summaryrefslogtreecommitdiff
path: root/protocols/MSN/src/msn_misc.cpp
diff options
context:
space:
mode:
authorGeorge Hazan <george.hazan@gmail.com>2016-09-17 16:37:24 +0000
committerGeorge Hazan <george.hazan@gmail.com>2016-09-17 16:37:24 +0000
commite5d58fc3bbbce2773b7c6c3f8b7da6faa66b672e (patch)
tree6432409a59b53d8098ac38aa1d3072ae2e5f9e4b /protocols/MSN/src/msn_misc.cpp
parent17e345e621254103a98bbc7e662a2829b7aa3ce6 (diff)
chats: more functions, less structures
git-svn-id: http://svn.miranda-ng.org/main/trunk@17309 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'protocols/MSN/src/msn_misc.cpp')
-rw-r--r--protocols/MSN/src/msn_misc.cpp10
1 files changed, 3 insertions, 7 deletions
diff --git a/protocols/MSN/src/msn_misc.cpp b/protocols/MSN/src/msn_misc.cpp
index ad4ac92d1a..e610b9c87a 100644
--- a/protocols/MSN/src/msn_misc.cpp
+++ b/protocols/MSN/src/msn_misc.cpp
@@ -396,13 +396,9 @@ void CMsnProto::MSN_GoOffline(void)
hContact = db_find_next(hContact, m_szModuleName))
{
if (isChatRoom(hContact) != 0) {
- DBVARIANT dbv;
- if (getWString(hContact, "ChatRoomID", &dbv) == 0) {
- GCDEST gcd = { m_szModuleName, dbv.ptszVal, GC_EVENT_CONTROL };
- GCEVENT gce = { sizeof(gce), &gcd };
- Chat_Event(SESSION_OFFLINE, &gce);
- db_free(&dbv);
- }
+ ptrW wszRoom(getWStringA(hContact, "ChatRoomID"));
+ if (wszRoom != NULL)
+ Chat_Control(m_szModuleName, wszRoom, SESSION_OFFLINE);
}
else {
if (ID_STATUS_OFFLINE != getWord(hContact, "Status", ID_STATUS_OFFLINE)) {