mirror of
https://github.com/thorvg/thorvg.git
synced 2025-06-16 13:04:48 +00:00
loader/jpg: fix a sanitizer report.
Bypass the operation involving a negative value shift. ../src/loaders/jpg/tvgJpgd.cpp:434:36: runtime error: left shift of negative value -5
This commit is contained in:
parent
c2ca01a5c5
commit
cd71c66703
1 changed files with 1 additions and 1 deletions
|
@ -431,7 +431,7 @@ struct Row<1>
|
||||||
{
|
{
|
||||||
static void idct(int* pTemp, const jpgd_block_t* pSrc)
|
static void idct(int* pTemp, const jpgd_block_t* pSrc)
|
||||||
{
|
{
|
||||||
const int dcval = (pSrc[0] << PASS1_BITS);
|
const int dcval = pSrc[0] * (pSrc[0] * (PASS1_BITS * 2));
|
||||||
|
|
||||||
pTemp[0] = dcval;
|
pTemp[0] = dcval;
|
||||||
pTemp[1] = dcval;
|
pTemp[1] = dcval;
|
||||||
|
|
Loading…
Add table
Reference in a new issue