diff options
author | Andreas Rheinhardt <andreas.rheinhardt@outlook.com> | 2022-01-03 13:48:39 +0100 |
---|---|---|
committer | Andreas Rheinhardt <andreas.rheinhardt@outlook.com> | 2022-01-08 18:17:40 +0100 |
commit | ffb000fff8f945a5b30f1df8ab1cb2e8300cdabd (patch) | |
tree | c003957df6fc26626fc3b7a933b7b5708f4007f2 | |
parent | 52c1e9e530a46ba62b974f121c9d28a86900a632 (diff) |
avcodec/jpeglsdec: Avoid get_bits_long() where possible
It is possible here, because the values of ff_log2_run used
here are actually in the range 0..15 given that run_index is
in the range 0..31.
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
-rw-r--r-- | libavcodec/jpeglsdec.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/libavcodec/jpeglsdec.c b/libavcodec/jpeglsdec.c index 32c0d2eb3f..269c71dc18 100644 --- a/libavcodec/jpeglsdec.c +++ b/libavcodec/jpeglsdec.c @@ -277,7 +277,7 @@ static inline int ls_decode_line(JLSState *state, MJpegDecodeContext *s, /* decode aborted run */ r = ff_log2_run[state->run_index[comp]]; if (r) - r = get_bits_long(&s->gb, r); + r = get_bits(&s->gb, r); if (x + r * stride > w) { r = (w - x) / stride; } |