diff options
-rw-r--r-- | protocols/VKontakte/src/vk_pollserver.cpp | 1 | ||||
-rw-r--r-- | protocols/VKontakte/src/vk_queue.cpp | 2 | ||||
-rw-r--r-- | protocols/VKontakte/src/vk_thread.cpp | 5 |
3 files changed, 5 insertions, 3 deletions
diff --git a/protocols/VKontakte/src/vk_pollserver.cpp b/protocols/VKontakte/src/vk_pollserver.cpp index e4a3b5524b..90edf659fb 100644 --- a/protocols/VKontakte/src/vk_pollserver.cpp +++ b/protocols/VKontakte/src/vk_pollserver.cpp @@ -211,7 +211,6 @@ int CVkProto::PollServer() }
else {
debugLogA("CVkProto::PollServer => ShutdownSession");
- m_hPollingThread = NULL;
ShutdownSession();
return 0;
}
diff --git a/protocols/VKontakte/src/vk_queue.cpp b/protocols/VKontakte/src/vk_queue.cpp index 57f71ceeb7..b62205cfde 100644 --- a/protocols/VKontakte/src/vk_queue.cpp +++ b/protocols/VKontakte/src/vk_queue.cpp @@ -172,7 +172,7 @@ void CVkProto::WorkerThread(void*) }
}
- m_hWorkerThread = 0;
+ m_hWorkerThread = NULL;
if (m_hAPIConnection) {
debugLogA("CVkProto::WorkerThread: Netlib_CloseHandle(m_hAPIConnection) beg");
Netlib_CloseHandle(m_hAPIConnection);
diff --git a/protocols/VKontakte/src/vk_thread.cpp b/protocols/VKontakte/src/vk_thread.cpp index 5a5563f3d8..5a2a59a5b3 100644 --- a/protocols/VKontakte/src/vk_thread.cpp +++ b/protocols/VKontakte/src/vk_thread.cpp @@ -102,11 +102,14 @@ void CVkProto::OnLoggedOut() debugLogA("CVkProto::OnLoggedOut");
m_bOnline = false;
+ m_hPollingThread = NULL;
+ m_hWorkerThread = NULL;
+
if (m_hAPIConnection)
Netlib_CloseHandle(m_hAPIConnection);
if (m_pollingConn)
- CallService(MS_NETLIB_SHUTDOWN, (WPARAM)m_pollingConn);
+ Netlib_Shutdown(m_pollingConn);
ProtoBroadcastAck(NULL, ACKTYPE_STATUS, ACKRESULT_SUCCESS, (HANDLE)m_iStatus, ID_STATUS_OFFLINE);
m_iStatus = m_iDesiredStatus = ID_STATUS_OFFLINE;
|