From 5e1c37f13c77b3c0694085d11179a4356ab72079 Mon Sep 17 00:00:00 2001 From: Tor Andersson Date: Thu, 24 Jul 2014 15:27:29 +0200 Subject: cbz: Only include each entry once, even if it matches many file suffixes. Bug 695377. --- source/cbz/mucbz.c | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'source') diff --git a/source/cbz/mucbz.c b/source/cbz/mucbz.c index 06b1080e..f018d1c9 100644 --- a/source/cbz/mucbz.c +++ b/source/cbz/mucbz.c @@ -281,9 +281,16 @@ cbz_read_zip_dir_imp(cbz_document *doc, int startoffset) doc->page = fz_malloc_array(ctx, count, sizeof(int)); for (i = 0; i < count; i++) + { for (k = 0; cbz_ext_list[k]; k++) + { if (strstr(doc->entry[i].name, cbz_ext_list[k])) + { doc->page[doc->page_count++] = i; + break; + } + } + } } static void -- cgit v1.2.3