summaryrefslogtreecommitdiff
path: root/protocols/IcqOscarJ
diff options
context:
space:
mode:
authorGeorge Hazan <george.hazan@gmail.com>2013-08-16 12:31:41 +0000
committerGeorge Hazan <george.hazan@gmail.com>2013-08-16 12:31:41 +0000
commit49fc1a8b9b5858974f90b9d2ed14ba5442c8cbfc (patch)
tree0f2e69541ce8636e696459326872299a4c201489 /protocols/IcqOscarJ
parent30ee89a6764a8d38a078374c6ed5de70635b42c0 (diff)
mir_md5_byte_t => BYTE;
macros mir_base64_encode_bufsize for calculating buffer size macros mir_base64_encodebuf for in-place base64 encoding git-svn-id: http://svn.miranda-ng.org/main/trunk@5716 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'protocols/IcqOscarJ')
-rw-r--r--protocols/IcqOscarJ/src/fam_17signon.cpp2
-rw-r--r--protocols/IcqOscarJ/src/icq_avatar.cpp12
2 files changed, 7 insertions, 7 deletions
diff --git a/protocols/IcqOscarJ/src/fam_17signon.cpp b/protocols/IcqOscarJ/src/fam_17signon.cpp
index dae5c38a0e..c4c546ca60 100644
--- a/protocols/IcqOscarJ/src/fam_17signon.cpp
+++ b/protocols/IcqOscarJ/src/fam_17signon.cpp
@@ -132,7 +132,7 @@ void CIcqProto::handleAuthKeyResponse(BYTE *buf, WORD wPacketLen, serverthread_i
WORD wKeyLen;
char szKey[64] = {0};
mir_md5_state_t state;
- mir_md5_byte_t digest[16];
+ BYTE digest[16];
#ifdef _DEBUG
NetLog_Server("Received %s", "ICQ_SIGNON_AUTH_KEY");
diff --git a/protocols/IcqOscarJ/src/icq_avatar.cpp b/protocols/IcqOscarJ/src/icq_avatar.cpp
index 363a9f2884..07dd17fc0f 100644
--- a/protocols/IcqOscarJ/src/icq_avatar.cpp
+++ b/protocols/IcqOscarJ/src/icq_avatar.cpp
@@ -196,11 +196,11 @@ BYTE* calcMD5HashOfFile(const TCHAR *tszFile)
{
long cbFileSize = GetFileSize(hFile, NULL);
- res = (BYTE*)SAFE_MALLOC(16 * sizeof(mir_md5_byte_t));
+ res = (BYTE*)SAFE_MALLOC(16 * sizeof(BYTE));
if (cbFileSize != 0 && res)
{
mir_md5_state_t state;
- mir_md5_byte_t digest[16];
+ BYTE digest[16];
int dwOffset = 0;
mir_md5_init(&state);
@@ -211,12 +211,12 @@ BYTE* calcMD5HashOfFile(const TCHAR *tszFile)
if (!(ppMap = (BYTE*)MapViewOfFile(hMap, FILE_MAP_READ, 0, dwOffset, dwBlockSize)))
break;
- mir_md5_append(&state, (const mir_md5_byte_t *)ppMap, dwBlockSize);
+ mir_md5_append(&state, (const BYTE *)ppMap, dwBlockSize);
UnmapViewOfFile(ppMap);
dwOffset += dwBlockSize;
}
mir_md5_finish(&state, digest);
- memcpy(res, digest, 16 * sizeof(mir_md5_byte_t));
+ memcpy(res, digest, 16 * sizeof(BYTE));
}
}
@@ -1593,10 +1593,10 @@ void avatars_server_connection::handleAvatarFam(BYTE *pBuffer, WORD wBufferLengt
if (pCookieData->hashlen == 0x14 && pCookieData->hash[3] == 0x10 && ppro->getByte("StrictAvatarCheck", DEFAULT_AVATARS_CHECK))
{ // check only standard hashes
mir_md5_state_t state;
- mir_md5_byte_t digest[16];
+ BYTE digest[16];
mir_md5_init(&state);
- mir_md5_append(&state, (const mir_md5_byte_t *)pBuffer, datalen);
+ mir_md5_append(&state, (const BYTE *)pBuffer, datalen);
mir_md5_finish(&state, digest);
// check if received data corresponds to specified hash
if (memcmp(pCookieData->hash+4, digest, 0x10)) aValid = 0;