diff options
author | George Hazan <ghazan@miranda.im> | 2019-07-24 20:58:51 +0300 |
---|---|---|
committer | George Hazan <ghazan@miranda.im> | 2019-07-24 20:58:58 +0300 |
commit | ed4897b7ef69e862806a8c07f1fd475262d0c36e (patch) | |
tree | 414efc6365f455122956eac74b754505c8efaf15 /protocols/Tox | |
parent | 99893bf3aec9f4e9f0c4844c0987d129e1778c7e (diff) |
massive warning fix
Diffstat (limited to 'protocols/Tox')
-rw-r--r-- | protocols/Tox/src/tox_accounts.cpp | 2 | ||||
-rw-r--r-- | protocols/Tox/src/tox_avatars.cpp | 6 | ||||
-rw-r--r-- | protocols/Tox/src/tox_transfer.cpp | 2 |
3 files changed, 5 insertions, 5 deletions
diff --git a/protocols/Tox/src/tox_accounts.cpp b/protocols/Tox/src/tox_accounts.cpp index ff40c4bb2e..c89f28fb82 100644 --- a/protocols/Tox/src/tox_accounts.cpp +++ b/protocols/Tox/src/tox_accounts.cpp @@ -8,7 +8,7 @@ int CToxProto::OnAccountRenamed(WPARAM wParam, LPARAM lParam) ptrW newPath(GetToxProfilePath());
wchar_t oldPath[MAX_PATH];
- mir_snwprintf(oldPath, MAX_PATH, L"%s\\%s.tox", VARSW(L"%miranda_userdata%"), m_accountName);
+ mir_snwprintf(oldPath, MAX_PATH, L"%s\\%s.tox", VARSW(L"%miranda_userdata%").get(), m_accountName);
_wrename(oldPath, newPath);
m_accountName = mir_wstrdup(m_tszUserName);
}
diff --git a/protocols/Tox/src/tox_avatars.cpp b/protocols/Tox/src/tox_avatars.cpp index 0e1aa6aa97..0a255512a0 100644 --- a/protocols/Tox/src/tox_avatars.cpp +++ b/protocols/Tox/src/tox_avatars.cpp @@ -3,7 +3,7 @@ wchar_t* CToxProto::GetAvatarFilePath(MCONTACT hContact)
{
wchar_t *path = (wchar_t*)mir_calloc(MAX_PATH * sizeof(wchar_t) + 1);
- mir_snwprintf(path, MAX_PATH, L"%s\\%S", VARSW(L"%miranda_avatarcache%"), m_szModuleName);
+ mir_snwprintf(path, MAX_PATH, L"%s\\%S", VARSW(L"%miranda_avatarcache%").get(), m_szModuleName);
DWORD dwAttributes = GetFileAttributes(path);
if (dwAttributes == 0xffffffff || (dwAttributes & FILE_ATTRIBUTE_DIRECTORY) == 0)
@@ -18,7 +18,7 @@ wchar_t* CToxProto::GetAvatarFilePath(MCONTACT hContact) if (hContact && mir_wstrlen(address) > TOX_PUBLIC_KEY_SIZE * 2)
address[TOX_PUBLIC_KEY_SIZE * 2] = 0;
- mir_snwprintf(path, MAX_PATH, L"%s\\%s.png", path, address);
+ mir_snwprintf(path, MAX_PATH, L"%s\\%s.png", path, address.get());
return path;
}
@@ -214,7 +214,7 @@ void CToxProto::OnGotFriendAvatarInfo(Tox *tox, AvatarTransferParam *transfer) }
wchar_t path[MAX_PATH];
- mir_snwprintf(path, L"%s\\%S", VARSW(L"%miranda_avatarcache%"), m_szModuleName);
+ mir_snwprintf(path, L"%s\\%S", VARSW(L"%miranda_avatarcache%").get(), m_szModuleName);
OnFileAllow(tox, transfer->pfts.hContact, transfer, path);
}
diff --git a/protocols/Tox/src/tox_transfer.cpp b/protocols/Tox/src/tox_transfer.cpp index f1939c2475..659b8d9e2e 100644 --- a/protocols/Tox/src/tox_transfer.cpp +++ b/protocols/Tox/src/tox_transfer.cpp @@ -23,7 +23,7 @@ void CToxProto::OnFriendFile(Tox *tox, uint32_t friendNumber, uint32_t fileNumbe ptrW address(proto->getWStringA(hContact, TOX_SETTINGS_ID));
wchar_t avatarName[MAX_PATH];
- mir_snwprintf(avatarName, MAX_PATH, L"%s.png", address);
+ mir_snwprintf(avatarName, MAX_PATH, L"%s.png", address.get());
AvatarTransferParam *transfer = new AvatarTransferParam(friendNumber, fileNumber, avatarName, fileSize);
transfer->pfts.flags |= PFTS_RECEIVING;
|