diff options
author | George Hazan <george.hazan@gmail.com> | 2013-08-15 20:00:29 +0000 |
---|---|---|
committer | George Hazan <george.hazan@gmail.com> | 2013-08-15 20:00:29 +0000 |
commit | 623722f7cc4c20d2b7d8df03035801acacda6018 (patch) | |
tree | d4c3686f935c12c9e9274cc3706bef12d9a20d86 /protocols/Tlen | |
parent | 8588345b7b8ff89bf90a216dbed2302fcf3ccdbc (diff) |
mir_sha1_byte_t => BYTE;
mir_sha1_long_t => ULONG;
mir_hmac_sha1 went to core
git-svn-id: http://svn.miranda-ng.org/main/trunk@5707 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'protocols/Tlen')
-rw-r--r-- | protocols/Tlen/src/jabber_util.cpp | 8 | ||||
-rw-r--r-- | protocols/Tlen/src/tlen_picture.cpp | 4 |
2 files changed, 6 insertions, 6 deletions
diff --git a/protocols/Tlen/src/jabber_util.cpp b/protocols/Tlen/src/jabber_util.cpp index 0fe8d0b10d..a219a5a573 100644 --- a/protocols/Tlen/src/jabber_util.cpp +++ b/protocols/Tlen/src/jabber_util.cpp @@ -259,8 +259,8 @@ char *JabberSha1(char *str) return NULL;
mir_sha1_init( &sha );
- mir_sha1_append( &sha, (mir_sha1_byte_t* )str, (int)strlen( str ));
- mir_sha1_finish( &sha, (mir_sha1_byte_t* )digest );
+ mir_sha1_append( &sha, (BYTE* )str, (int)strlen( str ));
+ mir_sha1_finish( &sha, (BYTE* )digest );
if ((result=(char *)mir_alloc(41)) == NULL)
return NULL;
sprintf(result, "%08x%08x%08x%08x%08x", (int)htonl(digest[0]), (int)htonl(digest[1]), (int)htonl(digest[2]), (int)htonl(digest[3]), (int)htonl(digest[4]));
@@ -270,7 +270,7 @@ char *JabberSha1(char *str) char *TlenSha1(char *str, int len)
{
mir_sha1_ctx sha;
- mir_sha1_byte_t digest[20];
+ BYTE digest[20];
char* result;
int i;
@@ -278,7 +278,7 @@ char *TlenSha1(char *str, int len) return NULL;
mir_sha1_init( &sha );
- mir_sha1_append( &sha, (mir_sha1_byte_t* )str, len);
+ mir_sha1_append( &sha, (BYTE* )str, len);
mir_sha1_finish( &sha, digest );
if (( result=( char* )mir_alloc( 20 )) == NULL )
return NULL;
diff --git a/protocols/Tlen/src/tlen_picture.cpp b/protocols/Tlen/src/tlen_picture.cpp index f6d896aa2e..55c4a1c07d 100644 --- a/protocols/Tlen/src/tlen_picture.cpp +++ b/protocols/Tlen/src/tlen_picture.cpp @@ -299,13 +299,13 @@ BOOL SendPicture(TlenProtocol *proto, HANDLE hContact) { int readcount = (int)fread(fileBuffer, (size_t)1, (size_t)toread, fp);
i -= readcount;
if (readcount > 0) {
- mir_sha1_append( &sha, (mir_sha1_byte_t* )fileBuffer, readcount);
+ mir_sha1_append( &sha, (BYTE* )fileBuffer, readcount);
}
if (toread != readcount) {
break;
}
}
- mir_sha1_finish( &sha, (mir_sha1_byte_t* )digest );
+ mir_sha1_finish( &sha, (BYTE* )digest );
JabberSend(proto, "<message type='pic' to='%s' crc='%08x%08x%08x%08x%08x' idt='%s' size='%d' ext='%s'/>", jid,
(int)htonl(digest[0]), (int)htonl(digest[1]), (int)htonl(digest[2]), (int)htonl(digest[3]), (int)htonl(digest[4]), idStr, item->ft->filesSize[0], "jpg");
} else {
|