summaryrefslogtreecommitdiff
path: root/plugins/PluginUpdater/src/Utils.cpp
diff options
context:
space:
mode:
authorGeorge Hazan <george.hazan@gmail.com>2013-11-07 20:53:09 +0000
committerGeorge Hazan <george.hazan@gmail.com>2013-11-07 20:53:09 +0000
commit6e25730bfafd9e4113cd9471544a2fe7491ebbf8 (patch)
tree45769d7324e5ba12489a0802a42ceb2adf6e3a24 /plugins/PluginUpdater/src/Utils.cpp
parent7288031deaffcbb9424dbad8496f6086f52a5066 (diff)
compilation fix for PU for Miranda IM
git-svn-id: http://svn.miranda-ng.org/main/trunk@6818 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins/PluginUpdater/src/Utils.cpp')
-rw-r--r--plugins/PluginUpdater/src/Utils.cpp16
1 files changed, 16 insertions, 0 deletions
diff --git a/plugins/PluginUpdater/src/Utils.cpp b/plugins/PluginUpdater/src/Utils.cpp
index bd2011cf96..3284c7e844 100644
--- a/plugins/PluginUpdater/src/Utils.cpp
+++ b/plugins/PluginUpdater/src/Utils.cpp
@@ -416,6 +416,22 @@ void strdel(TCHAR *parBuffer, int len )
}
#if MIRANDA_VER < 0x0A00
+static char szHexTable[] = "0123456789abcdef";
+
+char* bin2hex(const void *pData, size_t len, char *dest)
+{
+ const BYTE *p = (const BYTE*)pData;
+ char *d = dest;
+
+ for (size_t i=0; i < len; i++, p++) {
+ *d++ = szHexTable[*p >> 4];
+ *d++ = szHexTable[*p & 0x0F];
+ }
+ *d = 0;
+
+ return dest;
+}
+
char* rtrim(char *str)
{
if (str == NULL)