From a46eef0002d061c3363756182a592be7646ae79b Mon Sep 17 00:00:00 2001 From: James Bursa Date: Sun, 8 Sep 2002 18:11:56 +0000 Subject: [project @ 2002-09-08 18:11:56 by bursa] Add box_free(). svn path=/import/netsurf/; revision=32 --- render/layout.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'render/layout.c') diff --git a/render/layout.c b/render/layout.c index f2548d3cc..7d15fb11b 100644 --- a/render/layout.c +++ b/render/layout.c @@ -1,5 +1,5 @@ /** - * $Id: layout.c,v 1.13 2002/08/18 16:46:45 bursa Exp $ + * $Id: layout.c,v 1.14 2002/09/08 18:11:56 bursa Exp $ */ #include @@ -370,7 +370,7 @@ struct box * layout_line(struct box * first, unsigned long width, unsigned long b = c->next; } else { c2 = memcpy(xcalloc(1, sizeof(struct box)), c, sizeof(struct box)); - c2->text = space + 1; + c2->text = xstrdup(space + 1); c2->length = c->length - (c2->text - c->text); c->length = space - c->text; c2->next = c->next; @@ -394,7 +394,7 @@ struct box * layout_line(struct box * first, unsigned long width, unsigned long w = font_width(c->style, c->text, space2 - c->text); } c2 = memcpy(xcalloc(1, sizeof(struct box)), c, sizeof(struct box)); - c2->text = space + 1; + c2->text = xstrdup(space + 1); c2->length = c->length - (c2->text - c->text); c->length = space - c->text; c2->next = c->next; -- cgit v1.2.3