[markup] Simplify
Signed-off-by: Julien Danjou <julien@danjou.info>
This commit is contained in:
parent
088446e97d
commit
7b8e7bc486
|
@ -143,14 +143,11 @@ markup_parse_text(GMarkupParseContext *context __attribute__ ((unused)),
|
|||
GError **error __attribute__ ((unused)))
|
||||
{
|
||||
markup_parser_data_t *p = (markup_parser_data_t *) user_data;
|
||||
ssize_t len, rlen;
|
||||
char *esctext;
|
||||
ssize_t rlen;
|
||||
|
||||
len = a_strlen(p->text);
|
||||
rlen = len + 1 + text_len;
|
||||
rlen = a_strlen(p->text) + 1 + text_len;
|
||||
p_realloc(&p->text, rlen);
|
||||
esctext = g_markup_escape_text(text, text_len);
|
||||
a_strncat(p->text, rlen, esctext, a_strlen(esctext));
|
||||
a_strncat(p->text, rlen, text, text_len);
|
||||
}
|
||||
|
||||
/** Create a markup_parser_data_t structure with elements list.
|
||||
|
|
Loading…
Reference in New Issue