From c370af60855db957c5b200914bf0bde743845528 Mon Sep 17 00:00:00 2001 From: George Hazan Date: Fri, 28 Aug 2015 16:22:41 +0000 Subject: mir_sntprintf / mir_snprintf: obsoleted second parameter removed wherever possible git-svn-id: http://svn.miranda-ng.org/main/trunk@15064 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c --- plugins/UserInfoEx/src/svc_reminder.cpp | 21 ++++++++++----------- 1 file changed, 10 insertions(+), 11 deletions(-) (limited to 'plugins/UserInfoEx/src/svc_reminder.cpp') diff --git a/plugins/UserInfoEx/src/svc_reminder.cpp b/plugins/UserInfoEx/src/svc_reminder.cpp index f30b9ba1a4..44467f2fac 100644 --- a/plugins/UserInfoEx/src/svc_reminder.cpp +++ b/plugins/UserInfoEx/src/svc_reminder.cpp @@ -148,7 +148,7 @@ static HICON GetAnnivIcon(const CEvent &evt) if (evt._wDaysLeft > 9) hIcon = IcoLib_GetIcon(ICO_RMD_DTBX); else { - mir_snprintf(szIcon, _countof(szIcon), MODNAME"_rmd_dtb%u", evt._wDaysLeft); + mir_snprintf(szIcon, MODNAME"_rmd_dtb%u", evt._wDaysLeft); hIcon = IcoLib_GetIcon(szIcon); } break; @@ -157,7 +157,7 @@ static HICON GetAnnivIcon(const CEvent &evt) if (evt._wDaysLeft > 9) hIcon = IcoLib_GetIcon(ICO_RMD_DTAX); else { - mir_snprintf(szIcon, _countof(szIcon), MODNAME"_rmd_dta%u", evt._wDaysLeft); + mir_snprintf(szIcon, MODNAME"_rmd_dta%u", evt._wDaysLeft); hIcon = IcoLib_GetIcon(szIcon); } } @@ -183,7 +183,7 @@ static void NotifyWithExtraIcon(MCONTACT hContact, const CEvent &evt) if (evt._wDaysLeft > 9) icoName = ICO_RMD_DTAX; else { - mir_snprintf(szIcon, _countof(szIcon), MODNAME"_rmd_dtb%u", evt._wDaysLeft); + mir_snprintf(szIcon, MODNAME"_rmd_dtb%u", evt._wDaysLeft); icoName = szIcon; } break; @@ -192,7 +192,7 @@ static void NotifyWithExtraIcon(MCONTACT hContact, const CEvent &evt) if (evt._wDaysLeft > 9) icoName = ICO_RMD_DTAX; else { - mir_snprintf(szIcon, _countof(szIcon), MODNAME"_rmd_dta%u", evt._wDaysLeft); + mir_snprintf(szIcon, MODNAME"_rmd_dta%u", evt._wDaysLeft); icoName = szIcon; } break; @@ -255,8 +255,7 @@ static int NotifyWithPopup(MCONTACT hContact, CEvent::EType eventType, int DaysT if (hContact) { ppd.lchContact = hContact; - mir_sntprintf(ppd.lptzContactName, _countof(ppd.lptzContactName), - _T("%s - %s"), TranslateTS(pszDesc), DB::Contact::DisplayName(hContact)); + mir_sntprintf(ppd.lptzContactName, _T("%s - %s"), TranslateTS(pszDesc), DB::Contact::DisplayName(hContact)); } else mir_tstrncpy(ppd.lptzContactName, TranslateT("Reminder"), _countof(ppd.lptzContactName)); @@ -318,12 +317,12 @@ static void NotifyFlashCListIcon(MCONTACT hContact, const CEvent &evt) switch (evt._eType) { case CEvent::BIRTHDAY: - mir_sntprintf(szMsg, _countof(szMsg), TranslateT("%s has %s today."), DB::Contact::DisplayName(hContact), TranslateT("Birthday")); + mir_sntprintf(szMsg, TranslateT("%s has %s today."), DB::Contact::DisplayName(hContact), TranslateT("Birthday")); cle.hIcon = IcoLib_GetIcon(ICO_COMMON_BIRTHDAY); break; case CEvent::ANNIVERSARY: - mir_sntprintf(szMsg, _countof(szMsg), TranslateT("%s has %s today."), DB::Contact::DisplayName(hContact), TranslateT("an anniversary")); + mir_sntprintf(szMsg, TranslateT("%s has %s today."), DB::Contact::DisplayName(hContact), TranslateT("an anniversary")); cle.hIcon = IcoLib_GetIcon(ICO_COMMON_ANNIVERSARY); break; @@ -483,13 +482,13 @@ static bool CheckBirthday(MCONTACT hContact, MTime &Now, CEvent &evt, BYTE bNoti switch (Diff) { case 0: - cchMsg = mir_sntprintf(szMsg, _countof(szMsg), TranslateT("%s has birthday today."), DB::Contact::DisplayName(hContact)); + cchMsg = mir_sntprintf(szMsg, TranslateT("%s has birthday today."), DB::Contact::DisplayName(hContact)); break; case 1: - cchMsg = mir_sntprintf(szMsg, _countof(szMsg), TranslateT("%s has birthday tomorrow."), DB::Contact::DisplayName(hContact)); + cchMsg = mir_sntprintf(szMsg, TranslateT("%s has birthday tomorrow."), DB::Contact::DisplayName(hContact)); break; default: - cchMsg = mir_sntprintf(szMsg, _countof(szMsg), TranslateT("%s has birthday in %d days."), DB::Contact::DisplayName(hContact), Diff); + cchMsg = mir_sntprintf(szMsg, TranslateT("%s has birthday in %d days."), DB::Contact::DisplayName(hContact), Diff); } int age = mtb.Age(&Now); if (age > 0) -- cgit v1.2.3