projects
/
openjpeg.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
Fix negative shift left reported by UBSan (#758)
[openjpeg.git]
/
src
/
lib
/
openjp2
/
t1.c
diff --git
a/src/lib/openjp2/t1.c
b/src/lib/openjp2/t1.c
index 108ce78b603ca9eac60b533ec4386f91077135cc..a3ca93e8f6c67caf1c542d1c8e0ec975a8dc52f3 100644
(file)
--- a/
src/lib/openjp2/t1.c
+++ b/
src/lib/openjp2/t1.c
@@
-1514,7
+1514,7
@@
OPJ_BOOL opj_t1_encode_cblks( opj_t1_t *t1,
if (tccp->qmfbid == 1) {
for (j = 0; j < cblk_h; ++j) {
for (i = 0; i < cblk_w; ++i) {
- tiledp[tileIndex]
<<= T1_NMSEDEC_FRACBITS
;
+ tiledp[tileIndex]
*= (1 << T1_NMSEDEC_FRACBITS)
;
tileIndex++;
}
tileIndex += tileLineAdvance;