[markup] Fix bad allocation size

Signed-off-by: Julien Danjou <julien@danjou.info>
This commit is contained in:
Julien Danjou 2008-04-28 21:52:36 +02:00
parent 44890c7c33
commit f1ccb31bca
1 changed files with 1 additions and 1 deletions

View File

@ -56,7 +56,7 @@ markup_parse_start_element(GMarkupParseContext *context __attribute__ ((unused))
if(!a_strcmp(element_name, p->elements[i])) if(!a_strcmp(element_name, p->elements[i]))
{ {
for(j = 0; attribute_names[j]; j++); for(j = 0; attribute_names[j]; j++);
p->attribute_names[i] = p_new(char *, j); p->attribute_names[i] = p_new(char *, ++j);
p->attribute_values[i] = p_new(char *, j); p->attribute_values[i] = p_new(char *, j);
for(j = 0; attribute_names[j]; j++) for(j = 0; attribute_names[j]; j++)