}
- text_part->flags |= RSPAMD_MIME_TEXT_PART_FLAG_BALANCED;
text_part->html = rspamd_html_process_part_full (
task->task_pool,
text_part->utf_raw_content,
};
#define RSPAMD_MIME_TEXT_PART_FLAG_UTF (1 << 0)
-#define RSPAMD_MIME_TEXT_PART_FLAG_BALANCED (1 << 1)
-#define RSPAMD_MIME_TEXT_PART_FLAG_EMPTY (1 << 2)
-#define RSPAMD_MIME_TEXT_PART_FLAG_HTML (1 << 3)
-#define RSPAMD_MIME_TEXT_PART_FLAG_8BIT_RAW (1 << 4)
-#define RSPAMD_MIME_TEXT_PART_FLAG_8BIT_ENCODED (1 << 5)
-#define RSPAMD_MIME_TEXT_PART_HAS_SUBNORMAL (1 << 6)
-#define RSPAMD_MIME_TEXT_PART_NORMALISED (1 << 7)
-#define RSPAMD_MIME_TEXT_PART_ATTACHMENT (1 << 8)
+#define RSPAMD_MIME_TEXT_PART_FLAG_EMPTY (1 << 1)
+#define RSPAMD_MIME_TEXT_PART_FLAG_HTML (1 << 2)
+#define RSPAMD_MIME_TEXT_PART_FLAG_8BIT_RAW (1 << 3)
+#define RSPAMD_MIME_TEXT_PART_FLAG_8BIT_ENCODED (1 << 4)
+#define RSPAMD_MIME_TEXT_PART_ATTACHMENT (1 << 5)
#define IS_TEXT_PART_EMPTY(part) ((part)->flags & RSPAMD_MIME_TEXT_PART_FLAG_EMPTY)
#define IS_TEXT_PART_UTF(part) ((part)->flags & RSPAMD_MIME_TEXT_PART_FLAG_UTF)
gboolean
rspamd_is_html_balanced (struct rspamd_task * task, GArray * args, void *unused)
{
- struct rspamd_mime_text_part *p;
- guint i;
- gboolean res = TRUE;
-
- PTR_ARRAY_FOREACH (MESSAGE_FIELD (task, text_parts), i, p) {
- if (IS_TEXT_PART_HTML (p)) {
- if (p->flags & RSPAMD_MIME_TEXT_PART_FLAG_BALANCED) {
- res = TRUE;
- }
- else {
- res = FALSE;
- break;
- }
- }
- }
-
- return res;
-
+ /* Totally broken but seems to be never used */
+ return TRUE;
}
gboolean