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 --- plugins/Folders/src/services.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'plugins/Folders/src/services.cpp') diff --git a/plugins/Folders/src/services.cpp b/plugins/Folders/src/services.cpp index dfd24f6b59..80fd22c6b2 100644 --- a/plugins/Folders/src/services.cpp +++ b/plugins/Folders/src/services.cpp @@ -79,15 +79,15 @@ INT_PTR GetPathService(WPARAM wParam, LPARAM lParam) int InitServices() { - CallService(MS_DB_GETPROFILEPATHT, SIZEOF(szCurrentProfilePath), (LPARAM)szCurrentProfilePath); - CallService(MS_DB_GETPROFILENAMET, SIZEOF(szCurrentProfile), (LPARAM)szCurrentProfile); + CallService(MS_DB_GETPROFILEPATHT, _countof(szCurrentProfilePath), (LPARAM)szCurrentProfilePath); + CallService(MS_DB_GETPROFILENAMET, _countof(szCurrentProfile), (LPARAM)szCurrentProfile); TCHAR *pos = _tcsrchr(szCurrentProfile, '.'); if (pos) *pos = 0; - GetModuleFileName(GetModuleHandleA("mir_app.dll"), szMirandaPath, SIZEOF(szMirandaPath)); + GetModuleFileName(GetModuleHandleA("mir_app.dll"), szMirandaPath, _countof(szMirandaPath)); pos = _tcsrchr(szMirandaPath, '\\'); if (pos) *pos = 0; TCHAR *szTemp = Utils_ReplaceVarsT(_T("%miranda_userdata%")); - mir_sntprintf(szUserDataPath, SIZEOF(szUserDataPath), szTemp); + mir_sntprintf(szUserDataPath, _countof(szUserDataPath), szTemp); mir_free(szTemp); CreateServiceFunction(MS_FOLDERS_GET_PATH, GetPathService); -- cgit v1.2.3