summaryrefslogtreecommitdiff
path: root/plugins/Quotes
diff options
context:
space:
mode:
authorGeorge Hazan <ghazan@miranda.im>2017-01-12 21:27:03 +0300
committerGeorge Hazan <ghazan@miranda.im>2017-01-12 21:27:03 +0300
commit3cb3883908e3168e5f955be3143771721614307a (patch)
treee160797994b28577e5fa71a4c790e1670e6f4035 /plugins/Quotes
parent6461f17159c83bfaeba1ecbd124ab53551f3e22d (diff)
Netlib_FreeHttpRequest() instead of MS_NETLIB_FREEHTTPREQUESTSTRUCT
Diffstat (limited to 'plugins/Quotes')
-rw-r--r--plugins/Quotes/src/HTTPSession.cpp11
1 files changed, 5 insertions, 6 deletions
diff --git a/plugins/Quotes/src/HTTPSession.cpp b/plugins/Quotes/src/HTTPSession.cpp
index ae0679b758..345b3d0cec 100644
--- a/plugins/Quotes/src/HTTPSession.cpp
+++ b/plugins/Quotes/src/HTTPSession.cpp
@@ -36,7 +36,7 @@ public:
nlu.flags = NUF_OUTGOING | NUF_HTTPCONNS | NUF_NOHTTPSOPTION | NUF_UNICODE;
nlu.szSettingsModule = QUOTES_PROTOCOL_NAME;
nlu.ptszDescriptiveName = TranslateT("Quotes HTTP connections");
- g_hNetLib = reinterpret_cast<HANDLE>(Netlib_RegisterUser(&nlu));
+ g_hNetLib = Netlib_RegisterUser(&nlu);
return (NULL != g_hNetLib);
}
@@ -83,8 +83,7 @@ public:
NETLIBHTTPREQUEST* pReply = NULL;
{
mir_cslock lck(m_mx);
- pReply = reinterpret_cast<NETLIBHTTPREQUEST*>(CallService(MS_NETLIB_HTTPTRANSACTION,
- reinterpret_cast<WPARAM>(g_hNetLib), reinterpret_cast<LPARAM>(&nlhr)));
+ pReply = Netlib_HttpTransaction(g_hNetLib, &nlhr);
}
if (pReply) {
@@ -109,7 +108,7 @@ public:
bResult = true;
}
- CallService(MS_NETLIB_FREEHTTPREQUESTSTRUCT, 0, reinterpret_cast<LPARAM>(pReply));
+ Netlib_FreeHttpRequest(pReply);
}
mir_free(nlhr.headers);
@@ -118,13 +117,13 @@ public:
}
private:
- static HANDLE g_hNetLib;
+ static HNETLIBUSER g_hNetLib;
typedef std::vector<char> TBuffer;
mutable TBuffer m_aURL;
mutable mir_cs m_mx;
};
-HANDLE CImplMI::g_hNetLib = NULL;
+HNETLIBUSER CImplMI::g_hNetLib = NULL;
CHTTPSession::CHTTPSession()
: m_pImpl(new CImplMI)