aboutsummaryrefslogtreecommitdiffstats
path: root/src/libserver/html.c
diff options
context:
space:
mode:
authorVsevolod Stakhov <vsevolod@highsecure.ru>2016-08-05 14:36:40 +0100
committerVsevolod Stakhov <vsevolod@highsecure.ru>2016-08-05 16:06:22 +0100
commitebb6979c7ee3e444c03f00ae04d0e63bcf9e53aa (patch)
tree2ae2b23791123f0e096aed10865a8a96dd3be350 /src/libserver/html.c
parent07baac0372c789492c3863afad319e1928b08de9 (diff)
downloadrspamd-ebb6979c7ee3e444c03f00ae04d0e63bcf9e53aa.tar.gz
rspamd-ebb6979c7ee3e444c03f00ae04d0e63bcf9e53aa.zip
[Minor] Forgotten to save file
Diffstat (limited to 'src/libserver/html.c')
-rw-r--r--src/libserver/html.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/libserver/html.c b/src/libserver/html.c
index ce388cf49..f7d5c7643 100644
--- a/src/libserver/html.c
+++ b/src/libserver/html.c
@@ -1649,6 +1649,15 @@ rspamd_html_process_block_tag (rspamd_mempool_t *pool, struct html_tag *tag,
}
}
+ /* Set bgcolor to the html bgcolor and font color to black as a last resort */
+ if (!bl->font_color.valid) {
+ bl->font_color.d.val = 0xffffffff;
+ bl->font_color.valid = TRUE;
+ }
+ if (!bl->background_color.valid) {
+ memcpy (&bl->background_color, &hc->bgcolor, sizeof (hc->bgcolor));
+ }
+
if (hc->blocks == NULL) {
hc->blocks = g_ptr_array_sized_new (64);
rspamd_mempool_add_destructor (pool, rspamd_ptr_array_free_hard,