summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--core/fxcodec/codec/fx_codec_fax.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/core/fxcodec/codec/fx_codec_fax.cpp b/core/fxcodec/codec/fx_codec_fax.cpp
index 9739101fec..8c4b215a1b 100644
--- a/core/fxcodec/codec/fx_codec_fax.cpp
+++ b/core/fxcodec/codec/fx_codec_fax.cpp
@@ -45,8 +45,8 @@ const uint8_t ZeroLeadPos[256] = {
4, 4, 4, 4, 4, 4, 4, 4, 5, 5, 5, 5, 6, 6, 7, 8,
};
-// Limit of image dimension, an arbitrary large number.
-const int kMaxImageDimension = 0x01FFFF;
+// Limit of image dimension. Use the same limit as the JBIG2 codecs.
+const int kMaxImageDimension = 65535;
int FindBit(const uint8_t* data_buf, int max_pos, int start_pos, bool bit) {
ASSERT(start_pos >= 0);