diff options
author | Sebastian Rasmussen <sebras@hotmail.com> | 2009-03-02 01:47:55 +0100 |
---|---|---|
committer | Sebastian Rasmussen <sebras@hotmail.com> | 2009-03-02 01:47:55 +0100 |
commit | 2b02f0965e580925bfa41b2c19a0f38ac4205e3e (patch) | |
tree | 05f85d93c9e329305714651e6ee7f8c7ef710c35 /apps | |
parent | 22eeb653463d68f79a746a54b12a398442f26d1e (diff) | |
download | mupdf-2b02f0965e580925bfa41b2c19a0f38ac4205e3e.tar.xz |
Handle single image filters when printing information.
Diffstat (limited to 'apps')
-rw-r--r-- | apps/pdftool.c | 15 |
1 files changed, 9 insertions, 6 deletions
diff --git a/apps/pdftool.c b/apps/pdftool.c index 8f637348..cedc4412 100644 --- a/apps/pdftool.c +++ b/apps/pdftool.c @@ -1831,12 +1831,15 @@ printinfo(char *filename, int show, int page) image[i]->page, fz_tonum(image[i]->pageref), fz_togen(image[i]->pageref)); - for (j = 0; j < fz_arraylen(image[i]->u.image.filter); j++) - { - printf("%s%s", - fz_toname(fz_arrayget(image[i]->u.image.filter, j)), - j == fz_arraylen(image[i]->u.image.filter) - 1 ? "" : " "); - } + if (fz_isarray(image[i]->u.image.filter)) + for (j = 0; j < fz_arraylen(image[i]->u.image.filter); j++) + { + printf("%s%s", + fz_toname(fz_arrayget(image[i]->u.image.filter, j)), + j == fz_arraylen(image[i]->u.image.filter) - 1 ? "" : " "); + } + else + printf("%s", fz_toname(image[i]->u.image.filter)); printf(" ] %dx%d %dbpc %s%s%s (%d %d R)\n", fz_toint(image[i]->u.image.width), |