summaryrefslogtreecommitdiff
path: root/plugins/NewAwaySysMod/src/Properties.h
diff options
context:
space:
mode:
authorGeorge Hazan <george.hazan@gmail.com>2015-06-19 19:35:42 +0000
committerGeorge Hazan <george.hazan@gmail.com>2015-06-19 19:35:42 +0000
commit4c814798c7bc7f6a0f92c21b027b26290622aa2f (patch)
tree9bbfb38bd639f352300aa16ff7c45f5a9b2dba6d /plugins/NewAwaySysMod/src/Properties.h
parentf0f0cd088f1ec3a85abee825ddbc214f3f6b92c3 (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 'plugins/NewAwaySysMod/src/Properties.h')
-rw-r--r--plugins/NewAwaySysMod/src/Properties.h6
1 files changed, 3 insertions, 3 deletions
diff --git a/plugins/NewAwaySysMod/src/Properties.h b/plugins/NewAwaySysMod/src/Properties.h
index c0dbd1dab7..50c3ee4762 100644
--- a/plugins/NewAwaySysMod/src/Properties.h
+++ b/plugins/NewAwaySysMod/src/Properties.h
@@ -123,7 +123,7 @@ public:
int cxIcon = GetSystemMetrics(SM_CXSMICON);
int cyIcon = GetSystemMetrics(SM_CYSMICON);
int i;
- for (i = 0; i < SIZEOF(Icons); i++) {
+ for (i = 0; i < _countof(Icons); i++) {
if (IconList.GetSize() > i && IconList[i])
DestroyIcon(IconList[i]);
@@ -317,7 +317,7 @@ public:
CString ProtoStatusToDBSetting(const char *Prefix, int MoreOpt_PerStatusID = 0)
{
if (!MoreOpt_PerStatusID || g_MoreOptPage.GetDBValueCopy(MoreOpt_PerStatusID)) {
- for (int i = 0; i < SIZEOF(StatusSettings); i++)
+ for (int i = 0; i < _countof(StatusSettings); i++)
if (Status == StatusSettings[i].Status)
return szProto ? (CString(Prefix) + "_" + szProto + "_" + StatusSettings[i].Setting) : (CString(Prefix) + StatusSettings[i].Setting);
}
@@ -381,7 +381,7 @@ public:
__inline CString StatusToDBSetting(int Status, const char *Prefix, int MoreOpt_PerStatusID = 0)
{
if (!MoreOpt_PerStatusID || g_MoreOptPage.GetDBValueCopy(MoreOpt_PerStatusID))
- for (int i = 0; i < SIZEOF(StatusSettings); i++)
+ for (int i = 0; i < _countof(StatusSettings); i++)
if (Status == StatusSettings[i].Status)
return CString(Prefix) + StatusSettings[i].Setting;