From: markus schnalke Date: Wed, 8 Mar 2017 12:31:31 +0000 (+0100) Subject: Fix sbr/parse_msgs.c for C89 compatibility X-Git-Tag: mmh-0.4~44 X-Git-Url: http://git.marmaro.de/?a=commitdiff_plain;h=d9b9dba7abf1c10248abfb5f64c13eb1c3ddcb40;p=mmh Fix sbr/parse_msgs.c for C89 compatibility --- diff --git a/sbr/parse_msgs.c b/sbr/parse_msgs.c index 00d9fb8..f42bd80 100644 --- a/sbr/parse_msgs.c +++ b/sbr/parse_msgs.c @@ -8,6 +8,7 @@ parse_msgs(const struct msgs_array *msgs, char *folder, struct msgs_array *files char *msgnam; struct msgs *f; char *path; + size_t i; if (folder) { path = toabsdir(folder); @@ -24,8 +25,7 @@ parse_msgs(const struct msgs_array *msgs, char *folder, struct msgs_array *files return -1; } - for (size_t i = 0; i < msgs->size; i++) { - + for (i = 0; i < msgs->size; i++) { if (*(msgs->msgs[i]) == '.' || *(msgs->msgs[i]) == '/') { app_msgarg(files, msgs->msgs[i]); continue; @@ -36,7 +36,7 @@ parse_msgs(const struct msgs_array *msgs, char *folder, struct msgs_array *files } } - for (size_t i = f->lowsel; i <= f->hghsel; i++) { + for (i = f->lowsel; i <= f->hghsel; i++) { if (is_selected(f, i)) { msgnam = mh_xstrdup(path); msgnam = add(m_name(i), msgnam);