summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xplugins/Watrack_MPD/src/main.cpp2
-rw-r--r--protocols/MRA/src/Mra_functions.cpp4
-rw-r--r--protocols/SkypeClassic/src/gchat.cpp14
3 files changed, 9 insertions, 11 deletions
diff --git a/plugins/Watrack_MPD/src/main.cpp b/plugins/Watrack_MPD/src/main.cpp
index 171bcc853c..85c595be9b 100755
--- a/plugins/Watrack_MPD/src/main.cpp
+++ b/plugins/Watrack_MPD/src/main.cpp
@@ -313,7 +313,7 @@ int GetStatus(HWND)
return Parser() ? -1 : gbState;
}
-WCHAR *GetFileName(HWND, int)
+WCHAR* GetFileName(HWND, int)
{
if(!ghConnection)
{
diff --git a/protocols/MRA/src/Mra_functions.cpp b/protocols/MRA/src/Mra_functions.cpp
index 9a44569713..3893bab587 100644
--- a/protocols/MRA/src/Mra_functions.cpp
+++ b/protocols/MRA/src/Mra_functions.cpp
@@ -184,10 +184,10 @@ void MraAddrListFree(MRA_ADDR_LIST *pmalAddrList)
bool DB_GetStaticStringA(MCONTACT hContact, LPCSTR lpszModule, LPCSTR lpszValueName, LPSTR lpszRetBuff, size_t dwRetBuffSize, size_t *pdwRetBuffSize)
{
bool bRet = false;
- size_t dwReadedStringLen, dwRetBuffSizeLocal;
+
DBVARIANT dbv = { 0 };
if (db_get_ws(hContact, lpszModule, lpszValueName, &dbv) == 0) {
- dwReadedStringLen = lstrlenW(dbv.pwszVal);
+ int dwRetBuffSizeLocal, dwReadedStringLen = lstrlenW(dbv.pwszVal);
if (lpszRetBuff && (dwRetBuffSize > dwReadedStringLen)) {
dwRetBuffSizeLocal = WideCharToMultiByte(MRA_CODE_PAGE, 0, dbv.pwszVal, dwReadedStringLen, lpszRetBuff, dwRetBuffSize, NULL, NULL);
(*((CHAR*)(lpszRetBuff + dwRetBuffSizeLocal))) = 0;
diff --git a/protocols/SkypeClassic/src/gchat.cpp b/protocols/SkypeClassic/src/gchat.cpp
index 02046beeca..37e075544e 100644
--- a/protocols/SkypeClassic/src/gchat.cpp
+++ b/protocols/SkypeClassic/src/gchat.cpp
@@ -845,13 +845,11 @@ void GCInit(void)
void GCExit(void)
{
DeleteCriticalSection (&m_GCMutex);
- for (int i=0;i<chatcount;i++) {
- if(chats[i]) {
- free(chats[i].szChatName);
- free(chats[i].mJoinedContacts);
- }
+
+ for (int i=0; i < chatcount; i++) {
+ free(chats[i].szChatName);
+ free(chats[i].mJoinedContacts);
}
- if (chats) free (chats);
- chats = NULL;
+ free(chats); chats = NULL;
chatcount = 0;
-} \ No newline at end of file
+}