Commit 123d81ee authored by Remy Foray's avatar Remy Foray

Fix memory allocation when decoding a stream changing bitdepth between CVS

This issue might cause a segmentation fault.
parent 40c03461
Pipeline #5975 passed with stage
in 15 minutes and 13 seconds
......@@ -65,10 +65,8 @@ void Reshape::createDec(int bitDepth)
m_lumaBD = bitDepth;
m_reshapeLUTSize = 1 << m_lumaBD;
m_initCW = m_reshapeLUTSize / PIC_CODE_CW_BINS;
if (m_fwdLUT.empty())
m_fwdLUT.resize(m_reshapeLUTSize, 0);
if (m_invLUT.empty())
m_invLUT.resize(m_reshapeLUTSize, 0);
m_fwdLUT.resize(m_reshapeLUTSize, 0);
m_invLUT.resize(m_reshapeLUTSize, 0);
if (m_binCW.empty())
m_binCW.resize(PIC_CODE_CW_BINS, 0);
if (m_inputPivot.empty())
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment