summaryrefslogtreecommitdiff
path: root/plugins/AvatarHistory/src
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/AvatarHistory/src')
-rw-r--r--plugins/AvatarHistory/src/AvatarDlg.cpp12
-rw-r--r--plugins/AvatarHistory/src/AvatarHistory.cpp4
-rw-r--r--plugins/AvatarHistory/src/utils.cpp8
3 files changed, 12 insertions, 12 deletions
diff --git a/plugins/AvatarHistory/src/AvatarDlg.cpp b/plugins/AvatarHistory/src/AvatarDlg.cpp
index a748ae039a..0747bf7041 100644
--- a/plugins/AvatarHistory/src/AvatarDlg.cpp
+++ b/plugins/AvatarHistory/src/AvatarDlg.cpp
@@ -136,7 +136,7 @@ static INT_PTR CALLBACK AvatarDlgProc(HWND hwnd,UINT uMsg,WPARAM wParam,LPARAM l
TCHAR *displayName = pcli->pfnGetContactDisplayName(data->hContact, 0);
if (displayName) {
TCHAR title[MAX_PATH];
- mir_sntprintf(title, _countof(title), TranslateT("Avatar History for %s"), displayName);
+ mir_sntprintf(title, TranslateT("Avatar History for %s"), displayName);
SetWindowText(hwnd, title);
}
@@ -374,7 +374,7 @@ int FillAvatarListFromFiles(HWND list, MCONTACT hContact)
WIN32_FIND_DATA finddata;
GetContactFolder(dir, hContact);
- mir_sntprintf(path, _countof(path), _T("%s\\*.*"), dir);
+ mir_sntprintf(path, _T("%s\\*.*"), dir);
HANDLE hFind = FindFirstFile(path, &finddata);
if (hFind == INVALID_HANDLE_VALUE)
@@ -384,7 +384,7 @@ int FillAvatarListFromFiles(HWND list, MCONTACT hContact)
{
if (finddata.cFileName[0] != '.')
{
- mir_sntprintf(path, _countof(path), _T("%s\\%s"), dir, finddata.cFileName);
+ mir_sntprintf(path, _T("%s\\%s"), dir, finddata.cFileName);
max_pos = AddFileToList(path,finddata.cFileName,finddata.cFileName,list);
}
}
@@ -401,7 +401,7 @@ int FillAvatarListFromFolder(HWND list, MCONTACT hContact)
WIN32_FIND_DATA finddata;
GetContactFolder(dir, hContact);
- mir_sntprintf(path, _countof(path), _T("%s\\*.lnk"), dir);
+ mir_sntprintf(path, _T("%s\\*.lnk"), dir);
HANDLE hFind = FindFirstFile(path, &finddata);
if (hFind == INVALID_HANDLE_VALUE)
@@ -412,7 +412,7 @@ int FillAvatarListFromFolder(HWND list, MCONTACT hContact)
if (finddata.cFileName[0] != '.')
{
TCHAR lnk[MAX_PATH];
- mir_sntprintf(lnk, _countof(lnk), _T("%s\\%s"), dir, finddata.cFileName);
+ mir_sntprintf(lnk, _T("%s\\%s"), dir, finddata.cFileName);
if (ResolveShortcut(lnk, path))
max_pos = AddFileToList(path,lnk,finddata.cFileName,list);
}
@@ -549,7 +549,7 @@ int ShowSaveDialog(HWND hwnd, TCHAR* fn, MCONTACT hContact)
TCHAR title[MAX_PATH];
if (displayName)
{
- mir_sntprintf(title, _countof(title), TranslateT("Save Avatar for %s"), displayName);
+ mir_sntprintf(title, TranslateT("Save Avatar for %s"), displayName);
ofn.lpstrTitle = title;
}
else
diff --git a/plugins/AvatarHistory/src/AvatarHistory.cpp b/plugins/AvatarHistory/src/AvatarHistory.cpp
index bbf9da67b1..e12e54d4f2 100644
--- a/plugins/AvatarHistory/src/AvatarHistory.cpp
+++ b/plugins/AvatarHistory/src/AvatarHistory.cpp
@@ -187,7 +187,7 @@ static int AvatarChanged(WPARAM hContact, LPARAM lParam)
else
GetProtocolFolder(history_filename, proto);
- mir_sntprintf(history_filename, _countof(history_filename),
+ mir_sntprintf(history_filename,
_T("%s\\%s"), history_filename, hash);
if (CopyImageFile(avatar->filename, history_filename))
@@ -236,7 +236,7 @@ static int PreShutdown(WPARAM, LPARAM)
static int ModulesLoaded(WPARAM, LPARAM)
{
- mir_sntprintf(basedir, _countof(basedir), _T("%s\\Avatars History"), profilePath);
+ mir_sntprintf(basedir, _T("%s\\Avatars History"), profilePath);
hFolder = FoldersRegisterCustomPathT( LPGEN("Avatars"), LPGEN("Avatar History"),
PROFILE_PATHT _T("\\") CURRENT_PROFILET _T("\\Avatars History"));
diff --git a/plugins/AvatarHistory/src/utils.cpp b/plugins/AvatarHistory/src/utils.cpp
index 9344544a1e..637458b60d 100644
--- a/plugins/AvatarHistory/src/utils.cpp
+++ b/plugins/AvatarHistory/src/utils.cpp
@@ -151,7 +151,7 @@ TCHAR* GetContactFolder(TCHAR *fn, MCONTACT hContact)
#ifdef DBGPOPUPS
TCHAR log[1024];
- mir_sntprintf(log, _countof(log), _T("Path: %s\nProto: %S\nUIN: %s"), fn, proto, uin);
+ mir_sntprintf(log, _T("Path: %s\nProto: %S\nUIN: %s"), fn, proto, uin);
ShowPopup(hContact, _T("AVH Debug: GetContactFolder"), log);
#endif
@@ -178,7 +178,7 @@ void CreateOldStyleShortcut(MCONTACT hContact, TCHAR *history_filename)
GetOldStyleAvatarName(shortcut, hContact);
- mir_sntprintf(shortcut, _countof(shortcut), _T("%s.%s.lnk"), shortcut,
+ mir_sntprintf(shortcut, _T("%s.%s.lnk"), shortcut,
GetExtension(history_filename));
if (!CreateShortcut(history_filename, shortcut))
@@ -208,7 +208,7 @@ TCHAR * GetCachedAvatar(char *proto, TCHAR *hash)
else
GetProtocolFolder(file, proto);
- mir_sntprintf(search, _countof(search), _T("%s\\%s.*"), file, hash);
+ mir_sntprintf(search, _T("%s\\%s.*"), file, hash);
WIN32_FIND_DATA finddata;
HANDLE hFind = FindFirstFile(search, &finddata);
@@ -225,7 +225,7 @@ TCHAR * GetCachedAvatar(char *proto, TCHAR *hash)
|| !mir_tstrcmpi(&finddata.cFileName[len-4], _T(".jpg"))
|| !mir_tstrcmpi(&finddata.cFileName[len-5], _T(".jpeg"))))
{
- mir_sntprintf(file, _countof(file), _T("%s\\%s"), file, finddata.cFileName);
+ mir_sntprintf(file, _T("%s\\%s"), file, finddata.cFileName);
ret = mir_tstrdup(file);
break;
}