summaryrefslogtreecommitdiff
path: root/plugins/SendScreenshotPlus/src
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/SendScreenshotPlus/src
parent6461f17159c83bfaeba1ecbd124ab53551f3e22d (diff)
Netlib_FreeHttpRequest() instead of MS_NETLIB_FREEHTTPREQUESTSTRUCT
Diffstat (limited to 'plugins/SendScreenshotPlus/src')
-rw-r--r--plugins/SendScreenshotPlus/src/CSendHost_ImageShack.cpp6
-rw-r--r--plugins/SendScreenshotPlus/src/CSendHost_imgur.cpp6
-rw-r--r--plugins/SendScreenshotPlus/src/CSendHost_uploadpie.cpp6
3 files changed, 9 insertions, 9 deletions
diff --git a/plugins/SendScreenshotPlus/src/CSendHost_ImageShack.cpp b/plugins/SendScreenshotPlus/src/CSendHost_ImageShack.cpp
index bc52a13db7..143606a096 100644
--- a/plugins/SendScreenshotPlus/src/CSendHost_ImageShack.cpp
+++ b/plugins/SendScreenshotPlus/src/CSendHost_ImageShack.cpp
@@ -74,7 +74,7 @@ int CSendHost_ImageShack::Send()
void CSendHost_ImageShack::SendThread()
{
/// send DATA and wait for m_nlreply
- NETLIBHTTPREQUEST* reply = (NETLIBHTTPREQUEST*)CallService(MS_NETLIB_HTTPTRANSACTION, (WPARAM)g_hNetlibUser, (LPARAM)&m_nlhr);
+ NETLIBHTTPREQUEST* reply = Netlib_HttpTransaction(g_hNetlibUser, &m_nlhr);
HTTPFormDestroy(&m_nlhr);
if (reply) {
if (reply->resultCode >= 200 && reply->resultCode < 300 && reply->dataLength) {
@@ -95,7 +95,7 @@ void CSendHost_ImageShack::SendThread()
}
else mir_freeAndNil(m_URLthumb);
- CallService(MS_NETLIB_FREEHTTPREQUESTSTRUCT, 0, (LPARAM)reply);
+ Netlib_FreeHttpRequest(reply);
svcSendMsgExit(url); return;
}
else {/// check error mess from server
@@ -112,7 +112,7 @@ void CSendHost_ImageShack::SendThread()
}
else Error(SS_ERR_RESPONSE, m_pszSendTyp, reply->resultCode);
- CallService(MS_NETLIB_FREEHTTPREQUESTSTRUCT, 0, (LPARAM)reply);
+ Netlib_FreeHttpRequest(reply);
}
else Error(SS_ERR_NORESPONSE, m_pszSendTyp, m_nlhr.resultCode);
diff --git a/plugins/SendScreenshotPlus/src/CSendHost_imgur.cpp b/plugins/SendScreenshotPlus/src/CSendHost_imgur.cpp
index e87cc78e3f..b9738687e3 100644
--- a/plugins/SendScreenshotPlus/src/CSendHost_imgur.cpp
+++ b/plugins/SendScreenshotPlus/src/CSendHost_imgur.cpp
@@ -60,7 +60,7 @@ void CSendHost_Imgur::SendThread(void* obj)
{
CSendHost_Imgur* self = (CSendHost_Imgur*)obj;
/// send DATA and wait for m_nlreply
- NETLIBHTTPREQUEST* reply = (NETLIBHTTPREQUEST*)CallService(MS_NETLIB_HTTPTRANSACTION, (WPARAM)g_hNetlibUser, (LPARAM)&self->m_nlhr);
+ NETLIBHTTPREQUEST* reply = Netlib_HttpTransaction(g_hNetlibUser, &self->m_nlhr);
self->HTTPFormDestroy(&self->m_nlhr);
if (reply) {
if (reply->dataLength) {
@@ -79,14 +79,14 @@ void CSendHost_Imgur::SendThread(void* obj)
self->m_URLthumb[thumblen] = 'm'; // 320x320, see http://api.imgur.com/models/image
mir_strcpy(self->m_URLthumb + thumblen + 1, self->m_URL + thumblen);
}
- CallService(MS_NETLIB_FREEHTTPREQUESTSTRUCT, 0, (LPARAM)reply);
+ Netlib_FreeHttpRequest(reply);
self->svcSendMsgExit(self->m_URL); return;
}
else self->Error(SS_ERR_RESPONSE, self->m_pszSendTyp, GetJSONInteger(reply->pData, reply->dataLength, "status", 0));
}
else self->Error(SS_ERR_RESPONSE, self->m_pszSendTyp, reply->resultCode);
- CallService(MS_NETLIB_FREEHTTPREQUESTSTRUCT, 0, (LPARAM)reply);
+ Netlib_FreeHttpRequest(reply);
}
else self->Error(SS_ERR_NORESPONSE, self->m_pszSendTyp, self->m_nlhr.resultCode);
diff --git a/plugins/SendScreenshotPlus/src/CSendHost_uploadpie.cpp b/plugins/SendScreenshotPlus/src/CSendHost_uploadpie.cpp
index d354b0aaa1..eeaf4a9b89 100644
--- a/plugins/SendScreenshotPlus/src/CSendHost_uploadpie.cpp
+++ b/plugins/SendScreenshotPlus/src/CSendHost_uploadpie.cpp
@@ -66,7 +66,7 @@ void CSendHost_UploadPie::SendThread(void* obj)
{
CSendHost_UploadPie* self = (CSendHost_UploadPie*)obj;
/// send DATA and wait for m_nlreply
- NETLIBHTTPREQUEST* reply = (NETLIBHTTPREQUEST*)CallService(MS_NETLIB_HTTPTRANSACTION, (WPARAM)g_hNetlibUser, (LPARAM)&self->m_nlhr);
+ NETLIBHTTPREQUEST* reply = Netlib_HttpTransaction(g_hNetlibUser, &self->m_nlhr);
self->HTTPFormDestroy(&self->m_nlhr);
if (reply) {
if (reply->resultCode >= 200 && reply->resultCode < 300 && reply->dataLength) {
@@ -88,7 +88,7 @@ void CSendHost_UploadPie::SendThread(void* obj)
if (url) {
mir_free(self->m_URL), self->m_URL = mir_strdup(url);
- CallService(MS_NETLIB_FREEHTTPREQUESTSTRUCT, 0, (LPARAM)reply);
+ Netlib_FreeHttpRequest(reply);
self->svcSendMsgExit(url); return;
}
else {/// check error mess from server
@@ -102,7 +102,7 @@ void CSendHost_UploadPie::SendThread(void* obj)
}
else self->Error(SS_ERR_RESPONSE, self->m_pszSendTyp, reply->resultCode);
- CallService(MS_NETLIB_FREEHTTPREQUESTSTRUCT, 0, (LPARAM)reply);
+ Netlib_FreeHttpRequest(reply);
}
else self->Error(SS_ERR_NORESPONSE, self->m_pszSendTyp, self->m_nlhr.resultCode);