aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorVsevolod Stakhov <vsevolod@highsecure.ru>2015-10-06 16:04:42 +0100
committerVsevolod Stakhov <vsevolod@highsecure.ru>2015-10-06 16:04:42 +0100
commit2097ac107b192d6c244244ca425d012ebfcff09c (patch)
treeb174a3c18a5b24380e5468416f41aa103890f7da /src
parentc352bd7ff6a87ddc1079e81392185f94820a5072 (diff)
downloadrspamd-2097ac107b192d6c244244ca425d012ebfcff09c.tar.gz
rspamd-2097ac107b192d6c244244ca425d012ebfcff09c.zip
Fix html code.
Diffstat (limited to 'src')
-rw-r--r--src/libserver/html.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/src/libserver/html.c b/src/libserver/html.c
index 520c49d39..887924bd2 100644
--- a/src/libserver/html.c
+++ b/src/libserver/html.c
@@ -1350,7 +1350,7 @@ rspamd_html_process_img_tag (rspamd_mempool_t *pool, struct html_tag *tag,
{
struct html_tag_component *comp;
struct html_image *img;
- rspamd_fstring_t fstr;
+ rspamd_ftok_t fstr;
GList *cur;
gulong val;
@@ -1363,7 +1363,7 @@ rspamd_html_process_img_tag (rspamd_mempool_t *pool, struct html_tag *tag,
if (comp->type == RSPAMD_HTML_COMPONENT_HREF && comp->len > 0) {
fstr.begin = (gchar *)comp->start;
fstr.len = comp->len;
- img->src = rspamd_mempool_fstrdup (pool, &fstr);
+ img->src = rspamd_mempool_ftokdup (pool, &fstr);
if (comp->len > sizeof ("cid:") - 1 && memcmp (comp->start,
"cid:", sizeof ("cid:") - 1) == 0) {
@@ -1427,7 +1427,7 @@ struct html_color_match {
static gint
rspamd_html_color_cmp (const void *key, const void *elt)
{
- const rspamd_fstring_t *fk = key;
+ const rspamd_ftok_t *fk = key;
const struct html_color_match *el = elt;
return g_ascii_strncasecmp (fk->begin, el->name, fk->len);
@@ -1438,7 +1438,7 @@ rspamd_html_process_color (const gchar *line, guint len, struct html_color *cl)
{
const gchar *p = line, *end = line + len;
char hexbuf[7];
- rspamd_fstring_t search;
+ rspamd_ftok_t search;
struct html_color_match *el;
memset (cl, 0, sizeof (*cl));
@@ -1452,7 +1452,7 @@ rspamd_html_process_color (const gchar *line, guint len, struct html_color *cl)
}
else {
/* Compare color by name */
- search.begin = (gchar *)line;
+ search.begin = line;
search.len = len;
el = bsearch (&search, html_colors, G_N_ELEMENTS (html_colors),
@@ -1558,7 +1558,7 @@ rspamd_html_process_block_tag (rspamd_mempool_t *pool, struct html_tag *tag,
{
struct html_tag_component *comp;
struct html_block *bl;
- rspamd_fstring_t fstr;
+ rspamd_ftok_t fstr;
GList *cur;
cur = tag->params;
@@ -1583,7 +1583,7 @@ rspamd_html_process_block_tag (rspamd_mempool_t *pool, struct html_tag *tag,
else if (comp->type == RSPAMD_HTML_COMPONENT_CLASS && comp->len > 0) {
fstr.begin = (gchar *)comp->start;
fstr.len = comp->len;
- bl->class = rspamd_mempool_fstrdup (pool, &fstr);
+ bl->class = rspamd_mempool_ftokdup (pool, &fstr);
msg_debug_pool ("got class: %s", bl->class);
}