Browse Source

[Minor] Core: Fix length calculations

tags/1.9.0
Vsevolod Stakhov 5 years ago
parent
commit
5c8b497d76
1 changed files with 1 additions and 1 deletions
  1. 1
    1
      src/libutil/str_util.c

+ 1
- 1
src/libutil/str_util.c View File

@@ -935,7 +935,7 @@ rspamd_encode_qp_fold (const guchar *in, gsize inlen, gint str_len,
span += 3;
}

if (str_len > 0 && span >= str_len) {
if (str_len > 0 && span + 3 >= str_len) {
if (how == RSPAMD_TASK_NEWLINES_CRLF) {
/* =\r\n */
olen += 3;

Loading…
Cancel
Save