summaryrefslogtreecommitdiff
path: root/protocols/WhatsApp/src/utils.cpp
diff options
context:
space:
mode:
authorGeorge Hazan <george.hazan@gmail.com>2013-06-24 15:40:31 +0000
committerGeorge Hazan <george.hazan@gmail.com>2013-06-24 15:40:31 +0000
commitb40015c18a9acd7272d850df4389de98009a91f4 (patch)
tree9582786cb85e1a69ca48931965acc07c11486a09 /protocols/WhatsApp/src/utils.cpp
parent2f28d4cb509676a01cca5c18823309293faefef3 (diff)
memory leak fix inside bytesToHex
git-svn-id: http://svn.miranda-ng.org/main/trunk@5122 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'protocols/WhatsApp/src/utils.cpp')
-rw-r--r--protocols/WhatsApp/src/utils.cpp10
1 files changed, 9 insertions, 1 deletions
diff --git a/protocols/WhatsApp/src/utils.cpp b/protocols/WhatsApp/src/utils.cpp
index b78ef7f3b5..9559fb3372 100644
--- a/protocols/WhatsApp/src/utils.cpp
+++ b/protocols/WhatsApp/src/utils.cpp
@@ -113,7 +113,15 @@ BYTE* utils::md5string(const BYTE *data, int size, BYTE *digest)
return digest;
}
+/////////////////////////////////////////////////////////////////////////////////////////
+// external stubs for WhatsAPI++
+
std::string base64_encode(void* pData, size_t len)
{
return (char*)ptrA( mir_base64_encode((BYTE*)pData, (unsigned)len));
-} \ No newline at end of file
+}
+
+void md5_string(const std::string& data, BYTE digest[16])
+{
+ utils::md5string(data, digest);
+}