From 4c814798c7bc7f6a0f92c21b027b26290622aa2f Mon Sep 17 00:00:00 2001 From: George Hazan Date: Fri, 19 Jun 2015 19:35:42 +0000 Subject: SIZEOF replaced with more secure analog - _countof git-svn-id: http://svn.miranda-ng.org/main/trunk@14270 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c --- protocols/MSN/src/msn_menu.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'protocols/MSN/src/msn_menu.cpp') diff --git a/protocols/MSN/src/msn_menu.cpp b/protocols/MSN/src/msn_menu.cpp index 3899dc8cf8..e257a86e54 100644 --- a/protocols/MSN/src/msn_menu.cpp +++ b/protocols/MSN/src/msn_menu.cpp @@ -93,7 +93,7 @@ INT_PTR CMsnProto::MsnViewProfile(WPARAM hContact, LPARAM) } char tUrl[256]; - mir_snprintf(tUrl, SIZEOF(tUrl), "http://cid-%I64X.profiles.live.com", _atoi64(cid)); + mir_snprintf(tUrl, _countof(tUrl), "http://cid-%I64X.profiles.live.com", _atoi64(cid)); MsnInvokeMyURL(false, tUrl); return 0; } @@ -181,7 +181,7 @@ INT_PTR CMsnProto::MsnSendNetMeeting(WPARAM wParam, LPARAM) char msg[1024]; - mir_snprintf(msg, SIZEOF(msg), + mir_snprintf(msg, _countof(msg), "Content-Type: text/x-msmsgsinvite; charset=UTF-8\r\n\r\n" "Application-Name: NetMeeting\r\n" "Application-GUID: {44BBA842-CC51-11CF-AAFA-00AA00B6015C}\r\n" @@ -232,7 +232,7 @@ static INT_PTR CALLBACK DlgProcSetNickname(HWND hwndDlg, UINT msg, WPARAM wParam CMsnProto *proto = (CMsnProto*)GetWindowLongPtr(hwndDlg, GWLP_USERDATA); if (proto->msnLoggedIn) { TCHAR str[130]; - GetDlgItemText(hwndDlg, IDC_NICKNAME, str, SIZEOF(str)); + GetDlgItemText(hwndDlg, IDC_NICKNAME, str, _countof(str)); proto->MSN_SendNickname(str); } } @@ -349,7 +349,7 @@ void CMsnProto::MSN_EnableMenuItems(bool bEnable) if (!bEnable) mi.flags |= CMIF_GRAYED; - for (int i = 0; i < SIZEOF(menuItemsMain); i++) + for (int i = 0; i < _countof(menuItemsMain); i++) if (menuItemsMain[i] != NULL) Menu_ModifyItem(menuItemsMain[i], &mi); -- cgit v1.2.3