From: Vsevolod Stakhov Date: Fri, 16 Feb 2018 12:58:47 +0000 (+0000) Subject: [Fix] Fix variable increment X-Git-Tag: 1.7.0~174 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=2a22f706c2ee399e7932772be3ed94c47f487913;p=thirdparty%2Frspamd.git [Fix] Fix variable increment --- diff --git a/src/libutil/logger.c b/src/libutil/logger.c index 59e89158c0..1fade81642 100644 --- a/src/libutil/logger.c +++ b/src/libutil/logger.c @@ -1139,11 +1139,11 @@ file_log_function (const gchar *module, const gchar *id, } - iov[r++].iov_base = (void *) &lf_chr; + iov[r].iov_base = (void *) &lf_chr; iov[r++].iov_len = 1; if (rspamd_log->flags & RSPAMD_LOG_FLAG_COLOR) { - iov[r++].iov_base = "\033[0m"; + iov[r].iov_base = "\033[0m"; iov[r++].iov_len = sizeof ("\033[0m") - 1; /* Call helper (for buffering) */ file_log_helper (rspamd_log, iov, r, level_flags);