diff options
Diffstat (limited to 'src/frame.c')
-rw-r--r-- | src/frame.c | 9 |
1 files changed, 2 insertions, 7 deletions
diff --git a/src/frame.c b/src/frame.c index 5b16f32..c1dfd39 100644 --- a/src/frame.c +++ b/src/frame.c @@ -32,6 +32,7 @@ #include "sc_parse.h" #include "frame.h" #include "wrap.h" +#include "boxvec.h" static int alloc_ro(struct frame *fr) @@ -66,13 +67,7 @@ struct frame *frame_new() n->scblocks = NULL; - n->boxes = malloc(sizeof(struct wrap_line)); - if ( n->boxes == NULL ) { - fprintf(stderr, "Failed to allocate boxes.\n"); - free(n); - return NULL; - } - initialise_line(n->boxes); + n->boxes = bv_new(); return n; } |