summaryrefslogtreecommitdiff
path: root/protocols/Gadu-Gadu/src/ownerinfo.cpp
diff options
context:
space:
mode:
authorGoraf <22941576+Goraf@users.noreply.github.com>2018-01-20 16:25:13 +0100
committerGoraf <22941576+Goraf@users.noreply.github.com>2018-01-20 16:37:39 +0100
commit087173d06f4848f19d186b6902d399ce9b7225e1 (patch)
tree0cb2330486f445a2fa56c6da3a2d7ee983df6f52 /protocols/Gadu-Gadu/src/ownerinfo.cpp
parentde12828fb9051fba1db1e4573cff56ee83ab6b1f (diff)
Gadu-Gadu: code cleaning
Diffstat (limited to 'protocols/Gadu-Gadu/src/ownerinfo.cpp')
-rw-r--r--protocols/Gadu-Gadu/src/ownerinfo.cpp10
1 files changed, 5 insertions, 5 deletions
diff --git a/protocols/Gadu-Gadu/src/ownerinfo.cpp b/protocols/Gadu-Gadu/src/ownerinfo.cpp
index da6a5718c9..86928a99e5 100644
--- a/protocols/Gadu-Gadu/src/ownerinfo.cpp
+++ b/protocols/Gadu-Gadu/src/ownerinfo.cpp
@@ -20,11 +20,11 @@
#include "gg.h"
-typedef struct
+struct GG_REMIND_PASS
{
uin_t uin;
const char *email;
-} GG_REMIND_PASS;
+};
//////////////////////////////////////////////////////////
// remind password
@@ -32,9 +32,7 @@ typedef struct
void __cdecl GGPROTO::remindpasswordthread(void *param)
{
// Connection handle
- struct gg_http *h;
GG_REMIND_PASS *rp = (GG_REMIND_PASS *)param;
- GGTOKEN token;
debugLogA("remindpasswordthread(): Started.");
if (!rp || !rp->email || !rp->uin || !mir_strlen(rp->email))
@@ -47,6 +45,7 @@ void __cdecl GGPROTO::remindpasswordthread(void *param)
}
// Get token
+ GGTOKEN token;
if (!gettoken(&token)) {
#ifdef DEBUGMODE
debugLogA("remindpasswordthread(): End. err2");
@@ -54,7 +53,8 @@ void __cdecl GGPROTO::remindpasswordthread(void *param)
return;
}
- if (!(h = gg_remind_passwd3(rp->uin, rp->email, token.id, token.val, 0)))
+ gg_http *h = gg_remind_passwd3(rp->uin, rp->email, token.id, token.val, 0);
+ if (!h)
{
wchar_t error[128];
mir_snwprintf(error, TranslateT("Password could not be reminded because of error:\n\t%s (Error: %d)"), ws_strerror(errno), errno);