diff options
author | Vsevolod Stakhov <vsevolod@rspamd.com> | 2023-04-03 21:24:00 +0100 |
---|---|---|
committer | Vsevolod Stakhov <vsevolod@rspamd.com> | 2023-04-03 21:24:59 +0100 |
commit | e9fec3409a40bc89000d97130239a5867a1d6eb7 (patch) | |
tree | 915a5227998019327f575e28d748b1976d92ca9c /src/libmime/mime_headers.c | |
parent | f62b23fdebe3a0630121f1e515a5e2846b8ef827 (diff) | |
download | rspamd-e9fec3409a40bc89000d97130239a5867a1d6eb7.tar.gz rspamd-e9fec3409a40bc89000d97130239a5867a1d6eb7.zip |
[Minor] Do not propagate broken headers flag for attached messages
Diffstat (limited to 'src/libmime/mime_headers.c')
-rw-r--r-- | src/libmime/mime_headers.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/libmime/mime_headers.c b/src/libmime/mime_headers.c index f4001d640..e75a61366 100644 --- a/src/libmime/mime_headers.c +++ b/src/libmime/mime_headers.c @@ -237,7 +237,10 @@ rspamd_mime_headers_process (struct rspamd_task *task, } else if (g_ascii_isspace (*p)) { /* Not header but some garbage */ - task->flags |= RSPAMD_TASK_FLAG_BROKEN_HEADERS; + if (target == MESSAGE_FIELD (task, raw_headers)) { + /* Do not propagate flag from the attachments */ + task->flags |= RSPAMD_TASK_FLAG_BROKEN_HEADERS; + } state = 100; next_state = 0; } |