aboutsummaryrefslogtreecommitdiff
path: root/src/wrap.c
diff options
context:
space:
mode:
authorThomas White <taw@bitwiz.org.uk>2014-01-17 10:13:46 +0100
committerThomas White <taw@bitwiz.org.uk>2014-01-17 10:13:46 +0100
commit93956372d317fc90f8751e6b319e0055507c2519 (patch)
tree9c290978d9ad8a05a1da66ffc4839232b3102899 /src/wrap.c
parentbc49b9f3fd00ebc3bd62a51bb2321822618e838d (diff)
Unwrapped text belongs to frame, not interpreter
Diffstat (limited to 'src/wrap.c')
-rw-r--r--src/wrap.c7
1 files changed, 2 insertions, 5 deletions
diff --git a/src/wrap.c b/src/wrap.c
index 25f5d4d..782828a 100644
--- a/src/wrap.c
+++ b/src/wrap.c
@@ -803,7 +803,7 @@ void show_boxes(struct wrap_line *boxes)
/* Wrap the StoryCode inside "fr->sc" so that it fits within width "fr->w",
* and generate fr->lines */
-int wrap_contents(struct frame *fr, struct wrap_line *boxes)
+int wrap_contents(struct frame *fr)
{
struct wrap_line *para;
int i;
@@ -821,7 +821,7 @@ int wrap_contents(struct frame *fr, struct wrap_line *boxes)
i = 0;
do {
- para = split_paragraph(boxes, &i);
+ para = split_paragraph(fr->boxes, &i);
/* Split paragraphs into lines */
if ( para != NULL ) {
@@ -835,9 +835,6 @@ int wrap_contents(struct frame *fr, struct wrap_line *boxes)
} while ( para != NULL );
- free(boxes->boxes);
- free(boxes);
-
for ( i=0; i<fr->n_lines; i++ ) {
distribute_spaces(&fr->lines[i], wrap_w, rho);
calc_line_geometry(&fr->lines[i]);