summaryrefslogtreecommitdiff
path: root/src/mir_app
diff options
context:
space:
mode:
authorGeorge Hazan <ghazan@miranda.im>2017-02-05 22:03:00 +0300
committerGeorge Hazan <ghazan@miranda.im>2017-02-05 22:03:00 +0300
commit9000595b551d09cbaf14cbfd7b49aa5aca3d9a90 (patch)
treeea5e3f6abb32c518f7f82b10fbcc9ca67e70e13a /src/mir_app
parent48dd585af3311ef3e51bf081c37e61b56199a455 (diff)
proper fix for UINs in auth dialogs
Diffstat (limited to 'src/mir_app')
-rw-r--r--src/mir_app/src/db_events.cpp4
-rw-r--r--src/mir_app/src/mir_app.def1
-rw-r--r--src/mir_app/src/mir_app64.def1
3 files changed, 5 insertions, 1 deletions
diff --git a/src/mir_app/src/db_events.cpp b/src/mir_app/src/db_events.cpp
index 24dbeb55a8..dac49009ce 100644
--- a/src/mir_app/src/db_events.cpp
+++ b/src/mir_app/src/db_events.cpp
@@ -265,6 +265,7 @@ MIR_APP_DLL(wchar_t*) DbEvent_GetString(DBEVENTINFO *dbei, const char *str)
/////////////////////////////////////////////////////////////////////////////////////////
DB_AUTH_BLOB::DB_AUTH_BLOB(MCONTACT hContact, LPCSTR nick, LPCSTR fname, LPCSTR lname, LPCSTR email, LPCSTR reason) :
+ m_dwUin(0),
m_hContact(hContact),
m_szNick(mir_strdup(nick)),
m_szFirstName(mir_strdup(fname)),
@@ -278,6 +279,7 @@ DB_AUTH_BLOB::DB_AUTH_BLOB(MCONTACT hContact, LPCSTR nick, LPCSTR fname, LPCSTR
DB_AUTH_BLOB::DB_AUTH_BLOB(PBYTE blob)
{
PBYTE pCurBlob = blob;
+ m_dwUin = *(PDWORD)pCurBlob;
pCurBlob += sizeof(DWORD);
m_hContact = *(PDWORD)pCurBlob;
pCurBlob += sizeof(DWORD);
@@ -298,7 +300,7 @@ PBYTE DB_AUTH_BLOB::makeBlob()
PBYTE pBlob, pCurBlob;
pCurBlob = pBlob = (PBYTE)mir_alloc(m_size + 1);
- *((PDWORD)pCurBlob) = 0;
+ *((PDWORD)pCurBlob) = m_dwUin;
pCurBlob += sizeof(DWORD);
*((PDWORD)pCurBlob) = (DWORD)m_hContact;
pCurBlob += sizeof(DWORD);
diff --git a/src/mir_app/src/mir_app.def b/src/mir_app/src/mir_app.def
index 473761ff35..baf17bf743 100644
--- a/src/mir_app/src/mir_app.def
+++ b/src/mir_app/src/mir_app.def
@@ -398,3 +398,4 @@ Netlib_NtlmCreateResponse @383
Chat_UnescapeTags @399 NONAME
ProtoGetAvatarFormatByMimeType @400
ProtoGetAvatarMimeType @401
+?set_uin@DB_AUTH_BLOB@@QAEXK@Z @402 NONAME
diff --git a/src/mir_app/src/mir_app64.def b/src/mir_app/src/mir_app64.def
index 044ee43a95..b60684fb88 100644
--- a/src/mir_app/src/mir_app64.def
+++ b/src/mir_app/src/mir_app64.def
@@ -398,3 +398,4 @@ Netlib_NtlmCreateResponse @383
Chat_UnescapeTags @399 NONAME
ProtoGetAvatarFormatByMimeType @400
ProtoGetAvatarMimeType @401
+?set_uin@DB_AUTH_BLOB@@QEAAXK@Z @402 NONAME