Skip to content

Commit

Permalink
Fixed a NULL-pointer access in the line-based reconstruction process
Browse files Browse the repository at this point in the history
in case no valid scan was found and no data is present.
  • Loading branch information
Thomas Richter committed May 31, 2022
1 parent ea63151 commit 51c3241
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions control/linebitmaprequester.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@
** This class pulls blocks from the frame and reconstructs from those
** quantized block lines or encodes from them.
**
** $Id: linebitmaprequester.cpp,v 1.36 2021/07/22 13:18:36 thor Exp $
** $Id: linebitmaprequester.cpp,v 1.37 2022/05/31 10:16:52 thor Exp $
**
*/

Expand Down Expand Up @@ -562,7 +562,11 @@ void LineBitmapRequester::ReconstructRegion(const RectAngle<LONG> &orgregion,con
LONG *dst = m_ppCTemp[i];
if (i >= rr->rr_usFirstComponent && i <= rr->rr_usLastComponent) {
ExtractBitmap(m_ppTempIBM[i],r,i);
FetchRegion(x,*m_pppImage[i],dst);
if (*m_pppImage[i]) {
FetchRegion(x,*m_pppImage[i],dst);
} else {
memset(dst,0,sizeof(LONG) * 64);
}
} else {
memset(dst,0,sizeof(LONG) * 64);
}
Expand Down

0 comments on commit 51c3241

Please sign in to comment.