aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRagesh Radhakrishnan <ragesh.r@linaro.org>2014-02-27 10:51:30 +0530
committerRagesh Radhakrishnan <ragesh.r@linaro.org>2014-02-27 10:51:30 +0530
commitdaa963ecd83f182ac7879f97cb5d85af3f1e33f0 (patch)
tree0b3fc7f1ac0b22146837059c32182b0b585784a8
parentdb4bb6fa540a3940e9905dd4d3fa7e01c143069c (diff)
downloadlibjpeg-turbo.tar.gz
Redundant code removedlibjpeg-turbo
Redundant code reomoved from jpeg_calc_output_dimensions(). This piece of code is buggy to tile decode feature as the tile decode check.
-rw-r--r--jdmaster.c8
1 files changed, 2 insertions, 6 deletions
diff --git a/jdmaster.c b/jdmaster.c
index cacb9bf..5a35593 100644
--- a/jdmaster.c
+++ b/jdmaster.c
@@ -120,10 +120,10 @@ jpeg_core_output_dimensions (j_decompress_ptr cinfo)
#endif
/* Prevent application from calling me at wrong times */
-#if ANDROID
+#if ANDROID_TILE_BASED_DECODE
// Tile based decoding may call this function several times.
if (!cinfo->tile_decode)
-#endif /* ANDROID */
+#endif /* ANDROID_TILE_BASED_DECODE */
if (cinfo->global_state != DSTATE_READY)
ERREXIT1(cinfo, JERR_BAD_STATE, cinfo->global_state);
@@ -296,10 +296,6 @@ jpeg_calc_output_dimensions (j_decompress_ptr cinfo)
jpeg_component_info *compptr;
#endif
- /* Prevent application from calling me at wrong times */
- if (cinfo->global_state != DSTATE_READY)
- ERREXIT1(cinfo, JERR_BAD_STATE, cinfo->global_state);
-
/* Compute core output image dimensions and DCT scaling choices. */
jpeg_core_output_dimensions(cinfo);