diff options
author | George Hazan <george.hazan@gmail.com> | 2015-06-19 19:35:42 +0000 |
---|---|---|
committer | George Hazan <george.hazan@gmail.com> | 2015-06-19 19:35:42 +0000 |
commit | 4c814798c7bc7f6a0f92c21b027b26290622aa2f (patch) | |
tree | 9bbfb38bd639f352300aa16ff7c45f5a9b2dba6d /protocols/JabberG/src/jabber_bookmarks.cpp | |
parent | f0f0cd088f1ec3a85abee825ddbc214f3f6b92c3 (diff) |
SIZEOF replaced with more secure analog - _countof
git-svn-id: http://svn.miranda-ng.org/main/trunk@14270 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'protocols/JabberG/src/jabber_bookmarks.cpp')
-rw-r--r-- | protocols/JabberG/src/jabber_bookmarks.cpp | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/protocols/JabberG/src/jabber_bookmarks.cpp b/protocols/JabberG/src/jabber_bookmarks.cpp index 6a75105d87..bc33468517 100644 --- a/protocols/JabberG/src/jabber_bookmarks.cpp +++ b/protocols/JabberG/src/jabber_bookmarks.cpp @@ -104,12 +104,12 @@ static INT_PTR CALLBACK JabberAddBookmarkDlgProc(HWND hwndDlg, UINT msg, WPARAM switch (LOWORD(wParam)) {
case IDC_ROOM_JID:
if ((HWND)lParam==GetFocus() && HIWORD(wParam)==EN_CHANGE)
- EnableWindow(GetDlgItem(hwndDlg, IDOK), GetDlgItemText(hwndDlg, IDC_ROOM_JID, text, SIZEOF(text)));
+ EnableWindow(GetDlgItem(hwndDlg, IDOK), GetDlgItemText(hwndDlg, IDC_ROOM_JID, text, _countof(text)));
break;
case IDOK:
{
- GetDlgItemText(hwndDlg, IDC_ROOM_JID, text, SIZEOF(text));
+ GetDlgItemText(hwndDlg, IDC_ROOM_JID, text, _countof(text));
TCHAR *roomJID = NEWTSTR_ALLOCA(text);
if (param->m_item)
@@ -122,13 +122,13 @@ static INT_PTR CALLBACK JabberAddBookmarkDlgProc(HWND hwndDlg, UINT msg, WPARAM else
replaceStrT(item->type, _T("conference"));
- GetDlgItemText(hwndDlg, IDC_NICK, text, SIZEOF(text));
+ GetDlgItemText(hwndDlg, IDC_NICK, text, _countof(text));
replaceStrT(item->nick, text);
- GetDlgItemText(hwndDlg, IDC_PASSWORD, text, SIZEOF(text));
+ GetDlgItemText(hwndDlg, IDC_PASSWORD, text, _countof(text));
replaceStrT(item->password, text);
- GetDlgItemText(hwndDlg, IDC_NAME, text, SIZEOF(text));
+ GetDlgItemText(hwndDlg, IDC_NAME, text, _countof(text));
replaceStrT(item->name, (text[0] == 0) ? roomJID : text);
item->bAutoJoin = (IsDlgButtonChecked(hwndDlg, IDC_CHECK_BM_AUTOJOIN) == BST_CHECKED);
|