aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorVsevolod Stakhov <vsevolod@highsecure.ru>2018-01-29 07:38:12 +0000
committerVsevolod Stakhov <vsevolod@highsecure.ru>2018-01-29 07:38:12 +0000
commitea3353c2670e14e792779624da9892b0e74e797c (patch)
tree1ae8040981350e32086b76429c062aee6f1952ab
parent98170e8b0b5573b1049650193817a7f3ee6f1bd6 (diff)
downloadrspamd-ea3353c2670e14e792779624da9892b0e74e797c.tar.gz
rspamd-ea3353c2670e14e792779624da9892b0e74e797c.zip
[Fix] Fix comparision
Issue: #1998 MFH: rspamd-1.6
-rw-r--r--src/libserver/milter.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/libserver/milter.c b/src/libserver/milter.c
index 6fc4892ee..6ebf48838 100644
--- a/src/libserver/milter.c
+++ b/src/libserver/milter.c
@@ -450,7 +450,7 @@ rspamd_milter_process_command (struct rspamd_milter_session *session,
while (pos < end) {
zero = memchr (pos, '\0', cmdlen);
- if (zero == NULL || end >= zero) {
+ if (zero == NULL || zero >= end) {
err = g_error_new (rspamd_milter_quark (), EINVAL, "invalid "
"macro command (no name)");
rspamd_milter_on_protocol_error (session, priv, err);