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 /plugins/IEView/src/Template.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 'plugins/IEView/src/Template.cpp')
-rw-r--r-- | plugins/IEView/src/Template.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/plugins/IEView/src/Template.cpp b/plugins/IEView/src/Template.cpp index e9a6271fde..afbbeceab5 100644 --- a/plugins/IEView/src/Template.cpp +++ b/plugins/IEView/src/Template.cpp @@ -359,7 +359,7 @@ TemplateMap* TemplateMap::loadTemplateFile(const char *id, const char *filename, if (sscanf(store, "%s", tmp2) == EOF) continue;
//template start
bool bFound = false;
- for (unsigned i = 0; i < SIZEOF(templateNames); i++) {
+ for (unsigned i = 0; i < _countof(templateNames); i++) {
if (!strncmp(store, templateNames[i].tokenString, templateNames[i].tokenLen)) {
bFound = true;
break;
@@ -386,7 +386,7 @@ TemplateMap* TemplateMap::loadTemplateFile(const char *id, const char *filename, "MessageOutGroupStart", "MessageOutGroupInner",
"hMessageOutGroupStart", "hMessageOutGroupInner" };
tmap->grouping = true;
- for (i = 0; i < SIZEOF(groupTemplates); i++) {
+ for (i = 0; i < _countof(groupTemplates); i++) {
if (tmap->getTemplate(groupTemplates[i]) == NULL) {
tmap->grouping = false;
break;
@@ -394,7 +394,7 @@ TemplateMap* TemplateMap::loadTemplateFile(const char *id, const char *filename, }
static const char *rtlTemplates[] = { "MessageInRTL", "MessageOutRTL" }; //"HTMLStartRTL",
tmap->rtl = true;
- for (i = 0; i < SIZEOF(rtlTemplates); i++) {
+ for (i = 0; i < _countof(rtlTemplates); i++) {
if (tmap->getTemplate(rtlTemplates[i]) == NULL) {
tmap->rtl = false;
break;
|