From 226f16ddf41619caea347228322851835b4d1045 Mon Sep 17 00:00:00 2001 From: yzrh Date: Fri, 30 Dec 2022 12:20:49 +0000 Subject: Handle HN page with figure only. Signed-off-by: yzrh --- src/jbig.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'src/jbig.c') diff --git a/src/jbig.c b/src/jbig.c index fce8e02..b466411 100644 --- a/src/jbig.c +++ b/src/jbig.c @@ -108,7 +108,7 @@ static void _bytein(void) { if (_ret_pos < _scd_size) - _reg_c += *(_scd + _ret_pos++) << 8; + _reg_c += _scd[_ret_pos++] << 8; _ct = 8; } @@ -215,19 +215,19 @@ _procline(int line, char *a, char *b, char *c) cx >>= 1; if (_pix == 1) { - *(_ret + _width_padded * (_height - line - 1) + i / 8) |= _pix << (7 - (i & 0x07)); - *(c + i) = 1; + _ret[_width_padded * (_height - line - 1) + i / 8] |= _pix << (7 - (i & 0x07)); + c[i] = 1; cx |= 0x0200; } else { cx &= 0xfdff; } - if (i + 2 < _width && *(a + i + 2) == 1) + if (i + 2 < _width && a[i + 2] == 1) cx |= 0x0004; else cx &= 0xfffb; - if (i + 3 < _width && *(b + i + 3) == 1) + if (i + 3 < _width && b[i + 3] == 1) cx |= 0x0080; else cx &= 0xff7f; -- cgit v1.2.3