diff options
author | George Hazan <ghazan@miranda.im> | 2019-02-07 14:14:01 +0300 |
---|---|---|
committer | George Hazan <ghazan@miranda.im> | 2019-02-07 14:14:01 +0300 |
commit | 7d0d9f0db74fbd4750a9c19bd69f4cba368db40e (patch) | |
tree | 0507b0ae354ef1530f9be9935cc29f2672934678 | |
parent | 6429d32732b6d31561bcb2f080cd851c8c8ffe9d (diff) |
MSN: old unused stuff removed + version bump
-rw-r--r-- | protocols/MSN/src/msn_auth.cpp | 10 | ||||
-rw-r--r-- | protocols/MSN/src/msn_commands.cpp | 2 | ||||
-rw-r--r-- | protocols/MSN/src/msn_proto.cpp | 22 | ||||
-rw-r--r-- | protocols/MSN/src/msn_proto.h | 1 | ||||
-rw-r--r-- | protocols/MSN/src/msn_skypeab.cpp | 16 | ||||
-rw-r--r-- | protocols/MSN/src/msn_soapab.cpp | 2 | ||||
-rw-r--r-- | protocols/MSN/src/msn_ssl.cpp | 4 | ||||
-rw-r--r-- | protocols/MSN/src/version.h | 2 |
8 files changed, 20 insertions, 39 deletions
diff --git a/protocols/MSN/src/msn_auth.cpp b/protocols/MSN/src/msn_auth.cpp index 0580831dc4..176c42f1f9 100644 --- a/protocols/MSN/src/msn_auth.cpp +++ b/protocols/MSN/src/msn_auth.cpp @@ -287,7 +287,7 @@ bool SkypeToken::Refresh(bool bForce) nlhr.pData = szPOST.GetBuffer();
m_proto->mHttpsTS = clock();
- NETLIBHTTPREQUEST *nlhrReply = Netlib_HttpTransaction(m_proto->hNetlibUserHttps, &nlhr);
+ NETLIBHTTPREQUEST *nlhrReply = Netlib_HttpTransaction(m_proto->m_hNetlibUser, &nlhr);
m_proto->mHttpsTS = clock();
bool bRet = false;
@@ -698,7 +698,7 @@ bool CMsnProto::RefreshOAuth(const char *pszRefreshToken, const char *pszService // Query
mHttpsTS = clock();
- NETLIBHTTPREQUEST *nlhrReply = Netlib_HttpTransaction(hNetlibUserHttps, &nlhr);
+ NETLIBHTTPREQUEST *nlhrReply = Netlib_HttpTransaction(m_hNetlibUser, &nlhr);
mHttpsTS = clock();
if (nlhrReply) {
hHttpsConnection = nlhrReply->nlc;
@@ -1029,7 +1029,7 @@ int CMsnProto::MSN_AuthOAuth(void) // Get oauth20 login data
nlhr.szUrl = AUTH_URL;
mHttpsTS = clock();
- NETLIBHTTPREQUEST *nlhrReply = Netlib_HttpTransaction(hNetlibUserHttps, &nlhr);
+ NETLIBHTTPREQUEST *nlhrReply = Netlib_HttpTransaction(m_hNetlibUser, &nlhr);
mHttpsTS = clock();
if (nlhrReply) {
@@ -1054,7 +1054,7 @@ int CMsnProto::MSN_AuthOAuth(void) nlhr.flags &= (~NLHRF_REDIRECT);
mHttpsTS = clock();
nlhr.nlc = hHttpsConnection;
- NETLIBHTTPREQUEST *nlhrReply2 = Netlib_HttpTransaction(hNetlibUserHttps, &nlhr);
+ NETLIBHTTPREQUEST *nlhrReply2 = Netlib_HttpTransaction(m_hNetlibUser, &nlhr);
mHttpsTS = clock();
if (nlhrReply2) {
char *pszURL = nullptr, *pAccessToken, *pEnd;
@@ -1158,7 +1158,7 @@ int CMsnProto::MSN_AuthOAuth(void) mHttpsTS = clock();
if (nlhrReply)
Netlib_FreeHttpRequest(nlhrReply);
- nlhrReply = Netlib_HttpTransaction(hNetlibUserHttps, &nlhr);
+ nlhrReply = Netlib_HttpTransaction(m_hNetlibUser, &nlhr);
mHttpsTS = clock();
if (nlhrReply) {
hHttpsConnection = nlhrReply->nlc;
diff --git a/protocols/MSN/src/msn_commands.cpp b/protocols/MSN/src/msn_commands.cpp index 8eb13696b8..dd96ff43b7 100644 --- a/protocols/MSN/src/msn_commands.cpp +++ b/protocols/MSN/src/msn_commands.cpp @@ -402,7 +402,7 @@ void CMsnProto::MSN_ProcessURIObject(MCONTACT hContact, ezxml_t xmli) nlhr.nlc = hHttpsConnection;
mHttpsTS = clock();
- nlhrReply = Netlib_HttpTransaction(hNetlibUserHttps, &nlhr);
+ nlhrReply = Netlib_HttpTransaction(m_hNetlibUser, &nlhr);
mHttpsTS = clock();
if (nlhrReply) {
hHttpsConnection = nlhrReply->nlc;
diff --git a/protocols/MSN/src/msn_proto.cpp b/protocols/MSN/src/msn_proto.cpp index d49f560c11..1858516acc 100644 --- a/protocols/MSN/src/msn_proto.cpp +++ b/protocols/MSN/src/msn_proto.cpp @@ -123,28 +123,12 @@ CMsnProto::CMsnProto(const char* aProtoName, const wchar_t* aUserName) : InitCustomFolders();
wchar_t szBuffer[MAX_PATH];
- char szDbsettings[64];
-
- NETLIBUSER nlu1 = {};
- nlu1.flags = NUF_OUTGOING | NUF_HTTPCONNS | NUF_UNICODE;
- nlu1.szSettingsModule = szDbsettings;
- nlu1.szDescriptiveName.w = szBuffer;
-
- mir_snprintf(szDbsettings, "%s_HTTPS", m_szModuleName);
- mir_snwprintf(szBuffer, TranslateT("%s plugin HTTPS connections"), m_tszUserName);
- hNetlibUserHttps = Netlib_RegisterUser(&nlu1);
+ mir_snwprintf(szBuffer, TranslateT("%s plugin connections"), m_tszUserName);
NETLIBUSER nlu = {};
- nlu.flags = NUF_INCOMING | NUF_OUTGOING | NUF_HTTPCONNS | NUF_UNICODE;
+ nlu.flags = NUF_OUTGOING | NUF_HTTPCONNS | NUF_UNICODE;
nlu.szSettingsModule = m_szModuleName;
nlu.szDescriptiveName.w = szBuffer;
-
- nlu.szHttpGatewayUserAgent = (char*)MSN_USER_AGENT;
- nlu.pfnHttpGatewayInit = msn_httpGatewayInit;
- nlu.pfnHttpGatewayWrapSend = msn_httpGatewayWrapSend;
- nlu.pfnHttpGatewayUnwrapRecv = msn_httpGatewayUnwrapRecv;
-
- mir_snwprintf(szBuffer, TranslateT("%s plugin connections"), m_tszUserName);
m_hNetlibUser = Netlib_RegisterUser(&nlu);
m_DisplayNameCache = nullptr;
@@ -158,8 +142,6 @@ CMsnProto::~CMsnProto() Lists_Uninit();
CachedMsg_Uninit();
- Netlib_CloseHandle(hNetlibUserHttps);
-
mir_free(mailsoundname);
mir_free(alertsoundname);
diff --git a/protocols/MSN/src/msn_proto.h b/protocols/MSN/src/msn_proto.h index 53ce1aca40..ac5a2a14ed 100644 --- a/protocols/MSN/src/msn_proto.h +++ b/protocols/MSN/src/msn_proto.h @@ -169,7 +169,6 @@ struct CMsnProto : public PROTO<CMsnProto> clock_t mStatusMsgTS;
HANDLE msnSearchId;
- HNETLIBUSER hNetlibUserHttps;
HNETLIBCONN hHttpsConnection;
HANDLE hMSNNudge;
HANDLE hPopupError, hPopupHotmail, hPopupNotify;
diff --git a/protocols/MSN/src/msn_skypeab.cpp b/protocols/MSN/src/msn_skypeab.cpp index 4a5374d585..c759604fba 100644 --- a/protocols/MSN/src/msn_skypeab.cpp +++ b/protocols/MSN/src/msn_skypeab.cpp @@ -68,7 +68,7 @@ bool CMsnProto::MSN_SKYABRefreshClist(void) // Query addressbook
mHttpsTS = clock();
- NETLIBHTTPREQUEST *nlhrReply = Netlib_HttpTransaction(hNetlibUserHttps, &nlhr);
+ NETLIBHTTPREQUEST *nlhrReply = Netlib_HttpTransaction(m_hNetlibUser, &nlhr);
mHttpsTS = clock();
if (nlhrReply) {
hHttpsConnection = nlhrReply->nlc;
@@ -130,7 +130,7 @@ bool CMsnProto::MSN_SKYABGetProfiles(const char *pszPOST) nlhr.pData = (char*)pszPOST;
mHttpsTS = clock();
- NETLIBHTTPREQUEST *nlhrReply = Netlib_HttpTransaction(hNetlibUserHttps, &nlhr);
+ NETLIBHTTPREQUEST *nlhrReply = Netlib_HttpTransaction(m_hNetlibUser, &nlhr);
mHttpsTS = clock();
if (nlhrReply) {
hHttpsConnection = nlhrReply->nlc;
@@ -183,7 +183,7 @@ bool CMsnProto::MSN_SKYABGetProfile(const char *wlid) nlhr.szUrl = szURL;
mHttpsTS = clock();
- NETLIBHTTPREQUEST *nlhrReply = Netlib_HttpTransaction(hNetlibUserHttps, &nlhr);
+ NETLIBHTTPREQUEST *nlhrReply = Netlib_HttpTransaction(m_hNetlibUser, &nlhr);
mHttpsTS = clock();
if (nlhrReply) {
hHttpsConnection = nlhrReply->nlc;
@@ -261,7 +261,7 @@ bool CMsnProto::MSN_SKYABBlockContact(const char *wlid, const char *pszAction) nlhr.pData = szPOST;
mHttpsTS = clock();
- NETLIBHTTPREQUEST *nlhrReply = Netlib_HttpTransaction(hNetlibUserHttps, &nlhr);
+ NETLIBHTTPREQUEST *nlhrReply = Netlib_HttpTransaction(m_hNetlibUser, &nlhr);
mHttpsTS = clock();
if (nlhrReply) {
hHttpsConnection = nlhrReply->nlc;
@@ -289,7 +289,7 @@ bool CMsnProto::MSN_SKYABDeleteContact(const char *wlid) nlhr.headersCount++;
mHttpsTS = clock();
- NETLIBHTTPREQUEST *nlhrReply = Netlib_HttpTransaction(hNetlibUserHttps, &nlhr);
+ NETLIBHTTPREQUEST *nlhrReply = Netlib_HttpTransaction(m_hNetlibUser, &nlhr);
mHttpsTS = clock();
if (nlhrReply) {
hHttpsConnection = nlhrReply->nlc;
@@ -315,7 +315,7 @@ bool CMsnProto::MSN_SKYABAuthRsp(const char *wlid, const char *pszAction) nlhr.szUrl = szURL;
mHttpsTS = clock();
- NETLIBHTTPREQUEST *nlhrReply = Netlib_HttpTransaction(hNetlibUserHttps, &nlhr);
+ NETLIBHTTPREQUEST *nlhrReply = Netlib_HttpTransaction(m_hNetlibUser, &nlhr);
mHttpsTS = clock();
if (nlhrReply) {
hHttpsConnection = nlhrReply->nlc;
@@ -349,7 +349,7 @@ bool CMsnProto::MSN_SKYABAuthRq(const char *wlid, const char *pszGreeting) nlhr.pData = (char*)(const char*)post;
mHttpsTS = clock();
- NETLIBHTTPREQUEST *nlhrReply = Netlib_HttpTransaction(hNetlibUserHttps, &nlhr);
+ NETLIBHTTPREQUEST *nlhrReply = Netlib_HttpTransaction(m_hNetlibUser, &nlhr);
mHttpsTS = clock();
if (nlhrReply) {
hHttpsConnection = nlhrReply->nlc;
@@ -383,7 +383,7 @@ bool CMsnProto::MSN_SKYABSearch(const char *keyWord, HANDLE hSearch) nlhr.headersCount++;
mHttpsTS = clock();
- NETLIBHTTPREQUEST *nlhrReply = Netlib_HttpTransaction(hNetlibUserHttps, &nlhr);
+ NETLIBHTTPREQUEST *nlhrReply = Netlib_HttpTransaction(m_hNetlibUser, &nlhr);
mHttpsTS = clock();
if (nlhrReply) {
hHttpsConnection = nlhrReply->nlc;
diff --git a/protocols/MSN/src/msn_soapab.cpp b/protocols/MSN/src/msn_soapab.cpp index ae0a1260e4..d9f4194f81 100644 --- a/protocols/MSN/src/msn_soapab.cpp +++ b/protocols/MSN/src/msn_soapab.cpp @@ -862,7 +862,7 @@ bool CMsnProto::MSN_ABRefreshClist(unsigned int nTry) // Query addressbook
mHttpsTS = clock();
- NETLIBHTTPREQUEST *nlhrReply = Netlib_HttpTransaction(hNetlibUserHttps, &nlhr);
+ NETLIBHTTPREQUEST *nlhrReply = Netlib_HttpTransaction(m_hNetlibUser, &nlhr);
mHttpsTS = clock();
if (nlhrReply) {
hHttpsConnection = nlhrReply->nlc;
diff --git a/protocols/MSN/src/msn_ssl.cpp b/protocols/MSN/src/msn_ssl.cpp index b410708768..dbd9d2f7db 100644 --- a/protocols/MSN/src/msn_ssl.cpp +++ b/protocols/MSN/src/msn_ssl.cpp @@ -76,7 +76,7 @@ char* CMsnProto::getSslResult(char** parUrl, const char* parAuthInfo, const char }
// download the page
- NETLIBHTTPREQUEST *nlhrReply = Netlib_HttpTransaction(hNetlibUserHttps, &nlhr);
+ NETLIBHTTPREQUEST *nlhrReply = Netlib_HttpTransaction(m_hNetlibUser, &nlhr);
if (nlhrReply) {
hHttpsConnection = nlhrReply->nlc;
@@ -120,7 +120,7 @@ bool CMsnProto::getMyAvatarFile(char *url, wchar_t *fname) nlhr.headers[0].szValue = (char*)MSN_USER_AGENT;
// download the page
- NETLIBHTTPREQUEST *nlhrReply = Netlib_HttpTransaction(hNetlibUserHttps, &nlhr);
+ NETLIBHTTPREQUEST *nlhrReply = Netlib_HttpTransaction(m_hNetlibUser, &nlhr);
if (nlhrReply) {
if (nlhrReply->resultCode == 200 && nlhrReply->dataLength)
MSN_SetMyAvatar(fname, nlhrReply->pData, nlhrReply->dataLength);
diff --git a/protocols/MSN/src/version.h b/protocols/MSN/src/version.h index dc1a4dc97f..6477d7d501 100644 --- a/protocols/MSN/src/version.h +++ b/protocols/MSN/src/version.h @@ -20,7 +20,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>. #define __MAJOR_VERSION 0
#define __MINOR_VERSION 95
-#define __RELEASE_NUM 9
+#define __RELEASE_NUM 11
#define __BUILD_NUM 1
#include <stdver.h>
|