diff options
Diffstat (limited to 'protocols/VKontakte')
-rw-r--r-- | protocols/VKontakte/src/vk_proto.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_proto.cpp b/protocols/VKontakte/src/vk_proto.cpp index 5ae8f92020..3ae5ff7258 100644 --- a/protocols/VKontakte/src/vk_proto.cpp +++ b/protocols/VKontakte/src/vk_proto.cpp @@ -53,6 +53,7 @@ CVkProto::CVkProto(const char *szModuleName, const TCHAR *ptszUserName) : CVkProto::~CVkProto()
{
+ Netlib_CloseHandle(m_hNetlibUser); m_hNetlibUser = NULL;
UninitQueue();
}
diff --git a/protocols/VKontakte/src/vk_queue.cpp b/protocols/VKontakte/src/vk_queue.cpp index d25a585527..1b85a54691 100644 --- a/protocols/VKontakte/src/vk_queue.cpp +++ b/protocols/VKontakte/src/vk_queue.cpp @@ -52,7 +52,7 @@ LBL_Restart: bool CVkProto::PushAsyncHttpRequest(int iRequestType, LPCSTR szUrl, bool bSecure, VK_REQUEST_HANDLER pFunc, int nParams, HttpParam *pParams, int iTimeout)
{
AsyncHttpRequest *pReq = new AsyncHttpRequest();
- pReq->flags = NLHRF_NODUMPHEADERS | NLHRF_DUMPASTEXT | NLHRF_PERSISTENT | NLHRF_HTTP11 | NLHRF_REDIRECT;
+ pReq->flags = NLHRF_NODUMPHEADERS | NLHRF_DUMPASTEXT | NLHRF_HTTP11 | NLHRF_REDIRECT;
if (bSecure)
pReq->flags |= NLHRF_SSL;
diff --git a/protocols/VKontakte/src/vk_thread.cpp b/protocols/VKontakte/src/vk_thread.cpp index 0fcda29c50..4639e087b7 100644 --- a/protocols/VKontakte/src/vk_thread.cpp +++ b/protocols/VKontakte/src/vk_thread.cpp @@ -113,7 +113,7 @@ void CVkProto::OnOAuthAuthorize(NETLIBHTTPREQUEST *reply, AsyncHttpRequest *pReq else {
AsyncHttpRequest *pReq = new AsyncHttpRequest();
pReq->requestType = REQUEST_GET;
- pReq->flags = NLHRF_DUMPASTEXT | NLHRF_PERSISTENT | NLHRF_HTTP11;
+ pReq->flags = NLHRF_DUMPASTEXT | NLHRF_HTTP11;
pReq->m_pFunc = &CVkProto::OnOAuthAuthorize;
pReq->AddHeader("Referer", m_prevUrl);
pReq->Redirect(reply);
@@ -156,7 +156,7 @@ LBL_NoForm: pReq = new AsyncHttpRequest();
pReq->requestType = REQUEST_POST;
- pReq->flags = NLHRF_DUMPASTEXT | NLHRF_PERSISTENT | NLHRF_HTTP11;
+ pReq->flags = NLHRF_DUMPASTEXT | NLHRF_HTTP11;
pReq->pData = mir_strdup(szBody);
pReq->dataLength = szBody.GetLength();
pReq->szUrl = mir_strdup(szAction); m_prevUrl = pReq->szUrl;
@@ -491,6 +491,7 @@ int CVkProto::PollServer() req.requestType = REQUEST_GET;
req.szUrl = NEWSTR_ALLOCA(CMStringA().Format("%s?act=a_check&key=%s&ts=%s&wait=25&access_token=%s", m_pollingServer, m_pollingKey, m_pollingTs, m_szAccessToken));
req.flags = NLHRF_NODUMPHEADERS | NLHRF_HTTP11 | NLHRF_PERSISTENT;
+ req.nlc = m_pollingConn;
req.timeout = 30000;
NETLIBHTTPREQUEST *reply = (NETLIBHTTPREQUEST*)CallService(MS_NETLIB_HTTPTRANSACTION, (WPARAM)m_hNetlibUser, (LPARAM)&req);
|