diff options
author | Kirill Volinsky <mataes2007@gmail.com> | 2012-10-28 20:13:50 +0000 |
---|---|---|
committer | Kirill Volinsky <mataes2007@gmail.com> | 2012-10-28 20:13:50 +0000 |
commit | 4e5bbb877249745eca52e6bf1cc63e97e865ad83 (patch) | |
tree | 448a6873727e8a7731c33c71056365c0c9257791 | |
parent | 25fb34c76a42858dc732250b769bb08324d3a996 (diff) |
temporary fix for crash
git-svn-id: http://svn.miranda-ng.org/main/trunk@2106 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
-rw-r--r-- | protocols/Skype/src/skype_utils.cpp | 36 |
1 files changed, 18 insertions, 18 deletions
diff --git a/protocols/Skype/src/skype_utils.cpp b/protocols/Skype/src/skype_utils.cpp index f4fbc8486e..a998eda174 100644 --- a/protocols/Skype/src/skype_utils.cpp +++ b/protocols/Skype/src/skype_utils.cpp @@ -1,5 +1,5 @@ -#include "skype_proto.h" - +#include "skype_proto.h"
+
LanguagesListEntry CSkypeProto::languages[] =
{
{"Abkhazian", "ab"},
@@ -222,15 +222,15 @@ LanguagesListEntry CSkypeProto::languages[] = {"Zhuang", "za"},
{"Zulu", "zu"}
};
- - -void CSkypeProto::FakeAsync(void *param) -{ +
+
+void CSkypeProto::FakeAsync(void *param)
+{
::Sleep(100);
::CallService(MS_PROTO_BROADCASTACK, 0, (LPARAM)param);
- ::mir_free(param); -} - + ::mir_free(param);
+}
+
int CSkypeProto::DetectAvatarFormatBuffer(const char *pBuffer)
{
if (!strncmp(pBuffer, "%PNG", 4))
@@ -249,8 +249,8 @@ int CSkypeProto::DetectAvatarFormatBuffer(const char *pBuffer) return PA_FORMAT_BMP;
return PA_FORMAT_UNKNOWN;
-} - +}
+
int CSkypeProto::DetectAvatarFormat(const wchar_t *path)
{
int src = _wopen(path, _O_BINARY | _O_RDONLY, 0);
@@ -262,8 +262,8 @@ int CSkypeProto::DetectAvatarFormat(const wchar_t *path) _close(src);
return CSkypeProto::DetectAvatarFormatBuffer(pBuf);
-} - +}
+
wchar_t* CSkypeProto::GetContactAvatarFilePath(HANDLE hContact)
{
wchar_t* path = new wchar_t[MAX_PATH * 2];
@@ -299,18 +299,18 @@ wchar_t* CSkypeProto::GetContactAvatarFilePath(HANDLE hContact) // make sure the avatar cache directory exists
::CallService(MS_UTILS_CREATEDIRTREET, 0, (LPARAM)path);
- wchar_t *sid = this->GetSettingString("sid");
+ wchar_t *sid = this->GetSettingString("sid", ::mir_wstrdup(L""));
::wcscat(path, sid);
::wcscat(path, L".jpg");
::mir_free(sid);
- return path; -} - + return path;
+}
+
int CSkypeProto::CompareProtos(const CSkypeProto *p1, const CSkypeProto *p2)
{
return wcscmp(p1->m_tszUserName, p2->m_tszUserName);
-} +}
void CSkypeProto::CreateService(const char* szService, SkypeServiceFunc serviceProc)
{
|