diff options
author | Tor Andersson <tor.andersson@artifex.com> | 2016-01-07 13:37:48 +0100 |
---|---|---|
committer | Tor Andersson <tor.andersson@artifex.com> | 2016-01-08 13:00:45 +0100 |
commit | 63c8290faf4cec2c25a7ae4addde38ad2e5817f9 (patch) | |
tree | d1928c0bef84206e6d1db41a0e09b8d20d37315f /source/html/html-doc.c | |
parent | a57d4a1eb389fe63fb92207e574f1e1691cf5e4c (diff) | |
download | mupdf-63c8290faf4cec2c25a7ae4addde38ad2e5817f9.tar.xz |
epub: Fix memory leaks.
Diffstat (limited to 'source/html/html-doc.c')
-rw-r--r-- | source/html/html-doc.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/source/html/html-doc.c b/source/html/html-doc.c index 101a4c42..6ad5c3e8 100644 --- a/source/html/html-doc.c +++ b/source/html/html-doc.c @@ -117,7 +117,8 @@ htdoc_open_document_with_stream(fz_context *ctx, fz_stream *file) html_document *doc; fz_buffer *buf; - doc = fz_malloc_struct(ctx, html_document); + doc = fz_new_document(ctx, sizeof *doc); + doc->super.close = htdoc_close_document; doc->super.layout = htdoc_layout; doc->super.count_pages = htdoc_count_pages; |