summaryrefslogtreecommitdiff
path: root/protocols/SkypeWeb/src/skype_trouter.cpp
diff options
context:
space:
mode:
authorMikalaiR <nikolay.romanovich@narod.ru>2016-04-13 16:12:52 +0000
committerMikalaiR <nikolay.romanovich@narod.ru>2016-04-13 16:12:52 +0000
commit122306cee52b2da3694e3e04ad139fe92def1693 (patch)
treec5768c1aed3a65f3a74d0db80ffd7e05f5676e11 /protocols/SkypeWeb/src/skype_trouter.cpp
parentfdc5bdfae8a4a70cfd91ec0a8554005a3c0bbae2 (diff)
SkypeWeb: code cleaning
git-svn-id: http://svn.miranda-ng.org/main/trunk@16643 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'protocols/SkypeWeb/src/skype_trouter.cpp')
-rw-r--r--protocols/SkypeWeb/src/skype_trouter.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/protocols/SkypeWeb/src/skype_trouter.cpp b/protocols/SkypeWeb/src/skype_trouter.cpp
index a1b6768ce9..0f9506ad6c 100644
--- a/protocols/SkypeWeb/src/skype_trouter.cpp
+++ b/protocols/SkypeWeb/src/skype_trouter.cpp
@@ -139,12 +139,13 @@ void CSkypeProto::TRouterThread(void*)
m_hTrouterEvent.Wait();
errors = 0;
+ TrouterPollRequest *request = new TrouterPollRequest(TRouter.socketIo, TRouter.connId, TRouter.st, TRouter.se, TRouter.sig, TRouter.instance, TRouter.ccid, TRouter.sessId);
+
while (errors < POLLING_ERRORS_LIMIT && m_iStatus > ID_STATUS_OFFLINE)
{
- TrouterPollRequest *request = new TrouterPollRequest(TRouter.socketIo, TRouter.connId, TRouter.st, TRouter.se, TRouter.sig, TRouter.instance, TRouter.ccid, TRouter.sessId);
request->nlc = m_TrouterConnection;
NLHR_PTR response(request->Send(m_hNetlibUser));
- delete request;
+
if (response == NULL)
{
m_TrouterConnection = nullptr;
@@ -174,6 +175,7 @@ void CSkypeProto::TRouterThread(void*)
}
m_TrouterConnection = response->nlc;
}
+ delete request;
}
m_hTrouterThread = NULL;
m_TrouterConnection = NULL;