diff --git a/client.c b/client.c index bbe321b41..6f1e0e700 100644 --- a/client.c +++ b/client.c @@ -769,8 +769,7 @@ char * client_markup_parse(client_t *c, const char *str, ssize_t len) { const char *elements[] = { "title", NULL }; - char *title_esc = g_markup_escape_text(c->name, -1); - const char *elements_sub[] = { title_esc , NULL }; + const char *elements_sub[] = { c->name , NULL }; markup_parser_data_t p; char *ret; @@ -784,7 +783,6 @@ client_markup_parse(client_t *c, const char *str, ssize_t len) ret = a_strdup(str); markup_parser_data_wipe(&p); - p_delete(&title_esc); return ret; } diff --git a/common/markup.c b/common/markup.c index ecbf3254f..070ab3b61 100644 --- a/common/markup.c +++ b/common/markup.c @@ -64,7 +64,7 @@ markup_parse_start_element(GMarkupParseContext *context __attribute__ ((unused)) if(p->elements_sub && p->elements_sub[i]) { - buffer_adds(&p->text, p->elements_sub[i]); + buffer_add_xmlescaped(&p->text, p->elements_sub[i]); } return; diff --git a/widgets/taglist.c b/widgets/taglist.c index 1e28c25e2..75af0e75c 100644 --- a/widgets/taglist.c +++ b/widgets/taglist.c @@ -58,22 +58,18 @@ static char * tag_markup_parse(tag_t *t, const char *str, ssize_t len) { const char *elements[] = { "title", NULL }; - char *title_esc = g_markup_escape_text(t->name, -1); - const char *elements_sub[] = { title_esc , NULL }; + const char *elements_sub[] = { t->name , NULL }; markup_parser_data_t p; char *ret; markup_parser_data_init(&p, elements, elements_sub, countof(elements)); if(markup_parse(&p, str, len)) - { ret = buffer_detach(&p.text); - } else ret = a_strdup(str); markup_parser_data_wipe(&p); - p_delete(&title_esc); return ret; }