diff options
Diffstat (limited to 'converter/other/jpeg2000')
-rw-r--r-- | converter/other/jpeg2000/libjasper/base/jas_stream.c | 2 | ||||
-rw-r--r-- | converter/other/jpeg2000/pamtojpeg2k.c | 12 |
2 files changed, 8 insertions, 6 deletions
diff --git a/converter/other/jpeg2000/libjasper/base/jas_stream.c b/converter/other/jpeg2000/libjasper/base/jas_stream.c index 16c948eb..24f835ed 100644 --- a/converter/other/jpeg2000/libjasper/base/jas_stream.c +++ b/converter/other/jpeg2000/libjasper/base/jas_stream.c @@ -414,9 +414,11 @@ jas_stream_t *jas_stream_tmpfile() if (rc == 0) { pm_setjmpbuf(&jmpbuf); *obj = pm_tmpfile_fd(); + pm_setjmpbuf(NULL); } else { /* pm_tmpfile_fd() threw an error */ jas_stream_destroy(stream); + pm_setjmpbuf(NULL); return 0; } } diff --git a/converter/other/jpeg2000/pamtojpeg2k.c b/converter/other/jpeg2000/pamtojpeg2k.c index 4d73316a..a886c390 100644 --- a/converter/other/jpeg2000/pamtojpeg2k.c +++ b/converter/other/jpeg2000/pamtojpeg2k.c @@ -196,15 +196,15 @@ parseCommandLine(int argc, char ** argv, if (!ilyrratesSpec) cmdlineP->ilyrrates = (char*) ""; if (progressionSpec) { - if (strcmp(progressionOpt, "lrcp") == 0) + if (streq(progressionOpt, "lrcp")) cmdlineP->progression = PROG_LRCP; - if (strcmp(progressionOpt, "rlcp") == 0) + else if (streq(progressionOpt, "rlcp")) cmdlineP->progression = PROG_RLCP; - if (strcmp(progressionOpt, "rpcl") == 0) + else if (streq(progressionOpt, "rpcl")) cmdlineP->progression = PROG_RPCL; - if (strcmp(progressionOpt, "pcrl") == 0) + else if (streq(progressionOpt, "pcrl")) cmdlineP->progression = PROG_PCRL; - if (strcmp(progressionOpt, "cprl") == 0) + else if (streq(progressionOpt, "cprl")) cmdlineP->progression = PROG_CPRL; else pm_error("Invalid value for -progression: '%s'. " @@ -432,7 +432,7 @@ writeJpc(jas_image_t * const jasperP, cmdline.imgareatlx, cmdline.imgareatly, cmdline.tilegrdtlx, - cmdline.tilegrdtlx, + cmdline.tilegrdtly, cmdline.tilewidth, cmdline.tileheight, cmdline.prcwidth, |