diff options
author | Sebastian Rasmussen <sebras@gmail.com> | 2016-10-11 21:00:24 +0800 |
---|---|---|
committer | Sebastian Rasmussen <sebras@gmail.com> | 2016-10-12 01:53:15 +0800 |
commit | 91ac75c660d7d7100e4c55d63cbbd27729da351b (patch) | |
tree | 108c66ac09b9bf47a0548333e93da12d72ff584a | |
parent | 28d9c75ed780414a7ae71cab88cc86536444b255 (diff) | |
download | mupdf-91ac75c660d7d7100e4c55d63cbbd27729da351b.tar.xz |
Always call fz_drop_document() to drop the document.
-rw-r--r-- | source/cbz/mucbz.c | 2 | ||||
-rw-r--r-- | source/cbz/mutiff.c | 2 | ||||
-rw-r--r-- | source/gprf/gprf-doc.c | 2 | ||||
-rw-r--r-- | source/html/epub-doc.c | 2 | ||||
-rw-r--r-- | source/pdf/pdf-xref.c | 4 | ||||
-rw-r--r-- | source/xps/xps-zip.c | 4 |
6 files changed, 8 insertions, 8 deletions
diff --git a/source/cbz/mucbz.c b/source/cbz/mucbz.c index 23143fac..9fa522c8 100644 --- a/source/cbz/mucbz.c +++ b/source/cbz/mucbz.c @@ -213,7 +213,7 @@ cbz_open_document_with_stream(fz_context *ctx, fz_stream *file) } fz_catch(ctx) { - cbz_drop_document(ctx, doc); + fz_drop_document(ctx, &doc->super); fz_rethrow(ctx); } return doc; diff --git a/source/cbz/mutiff.c b/source/cbz/mutiff.c index fb88e11b..7817eb16 100644 --- a/source/cbz/mutiff.c +++ b/source/cbz/mutiff.c @@ -132,7 +132,7 @@ tiff_open_document_with_stream(fz_context *ctx, fz_stream *file) } fz_catch(ctx) { - tiff_drop_document(ctx, doc); + fz_drop_document(ctx, &doc->super); fz_rethrow(ctx); } diff --git a/source/gprf/gprf-doc.c b/source/gprf/gprf-doc.c index e269229e..8d6b3b32 100644 --- a/source/gprf/gprf-doc.c +++ b/source/gprf/gprf-doc.c @@ -965,7 +965,7 @@ gprf_open_document_with_stream(fz_context *ctx, fz_stream *file) } fz_catch(ctx) { - gprf_close_document(ctx, (fz_document*)doc); + fz_drop_document(ctx, &doc->super); fz_rethrow(ctx); } diff --git a/source/html/epub-doc.c b/source/html/epub-doc.c index efa43075..d9b0a0c9 100644 --- a/source/html/epub-doc.c +++ b/source/html/epub-doc.c @@ -463,7 +463,7 @@ epub_init(fz_context *ctx, fz_archive *zip) } fz_catch(ctx) { - epub_drop_document(ctx, (fz_document*)doc); + fz_drop_document(ctx, &doc->super); fz_rethrow(ctx); } diff --git a/source/pdf/pdf-xref.c b/source/pdf/pdf-xref.c index a1e2f88d..a054a837 100644 --- a/source/pdf/pdf-xref.c +++ b/source/pdf/pdf-xref.c @@ -2373,7 +2373,7 @@ pdf_open_document_with_stream(fz_context *ctx, fz_stream *file) } fz_catch(ctx) { - pdf_drop_document_imp(ctx, doc); + fz_drop_document(ctx, &doc->super); fz_rethrow(ctx); } return doc; @@ -2400,7 +2400,7 @@ pdf_open_document(fz_context *ctx, const char *filename) } fz_catch(ctx) { - pdf_drop_document_imp(ctx, doc); + fz_drop_document(ctx, &doc->super); fz_rethrow(ctx); } return doc; diff --git a/source/xps/xps-zip.c b/source/xps/xps-zip.c index 1d8f5bc8..6874a3b4 100644 --- a/source/xps/xps-zip.c +++ b/source/xps/xps-zip.c @@ -134,7 +134,7 @@ xps_open_document_with_directory(fz_context *ctx, const char *directory) } fz_catch(ctx) { - xps_drop_document(ctx, doc); + fz_drop_document(ctx, &doc->super); fz_rethrow(ctx); } @@ -156,7 +156,7 @@ xps_open_document_with_stream(fz_context *ctx, fz_stream *file) } fz_catch(ctx) { - xps_drop_document(ctx, doc); + fz_drop_document(ctx, &doc->super); fz_rethrow(ctx); } |