summaryrefslogtreecommitdiff
path: root/protocols/JabberG/src/jabber_events.cpp
diff options
context:
space:
mode:
authorGeorge Hazan <george.hazan@gmail.com>2013-07-20 14:23:07 +0000
committerGeorge Hazan <george.hazan@gmail.com>2013-07-20 14:23:07 +0000
commit5e4286f1becfb5ce52372f882a51ae8ea6f6ef6d (patch)
tree60e5dc3d3fa347ba34e1447e6b6e925c0e33c29b /protocols/JabberG/src/jabber_events.cpp
parentd7382326906b9f3bdd66704dd1b41f9299c1daa6 (diff)
- Jabber resource fix: in LAST_SEEN mode resource is skipped when no sessions were available;
- code cleanup; - version bump git-svn-id: http://svn.miranda-ng.org/main/trunk@5429 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'protocols/JabberG/src/jabber_events.cpp')
-rw-r--r--protocols/JabberG/src/jabber_events.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/protocols/JabberG/src/jabber_events.cpp b/protocols/JabberG/src/jabber_events.cpp
index 46412d2798..2a66c60b84 100644
--- a/protocols/JabberG/src/jabber_events.cpp
+++ b/protocols/JabberG/src/jabber_events.cpp
@@ -43,8 +43,9 @@ int CJabberProto::OnContactDeleted(WPARAM wParam, LPARAM)
if ( !m_bJabberOnline) // should never happen
return 0;
+ HANDLE hContact = (HANDLE)wParam;
DBVARIANT dbv;
- if ( !getTString((HANDLE)wParam, getByte((HANDLE) wParam, "ChatRoom", 0)?(char*)"ChatRoomID":(char*)"jid", &dbv)) {
+ if ( !getTString(hContact, isChatRoom(hContact) ? "ChatRoomID" : "jid", &dbv)) {
if (ListGetItemPtr(LIST_ROSTER, dbv.ptszVal)) {
if ( !_tcschr(dbv.ptszVal, _T('@'))) {
TCHAR szStrippedJid[JABBER_MAX_JID_LEN];
@@ -113,7 +114,7 @@ void __cdecl CJabberProto::OnRenameGroup(DBCONTACTWRITESETTING* cws, HANDLE hCon
}
}
else {
- TCHAR* p = sttSettingToTchar(cws);
+ TCHAR *p = sttSettingToTchar(cws);
if (cws->value.pszVal != NULL && lstrcmp(p, item->group)) {
Log("Group set to %S", p);
if (p)