vcl/source/filter/ixpm/xpmread.cxx | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-)
New commits: commit 10a7f48aa83aaf78ccd09d3cab1a961aa1e8219e Author: Caolán McNamara <caol...@redhat.com> Date: Fri Jan 13 11:41:55 2017 +0000 ofz: ensure all not explicitly set indexes are zero Change-Id: Idbe6ceeb61d3dfe26f281349181e7a60f7e59000 (cherry picked from commit 14d9b3519adac8543b52ddb84e49eecbdd1d9eb2) Reviewed-on: https://gerrit.libreoffice.org/33035 Tested-by: Jenkins <c...@libreoffice.org> Reviewed-by: Michael Stahl <mst...@redhat.com> diff --git a/vcl/source/filter/ixpm/xpmread.cxx b/vcl/source/filter/ixpm/xpmread.cxx index bdeacf9..3d22258 100644 --- a/vcl/source/filter/ixpm/xpmread.cxx +++ b/vcl/source/filter/ixpm/xpmread.cxx @@ -223,7 +223,9 @@ ReadState XPMReader::ReadXPM( Graphic& rGraphic ) // using 2 charakters per pixel and less than 257 Colors we speed up if ( mnCpp == 2 ) // by using a 64kb indexing table { - mpFastColorTable = new sal_uInt8[ 256 * 256 ]; + const size_t nSize = 256 * 256; + mpFastColorTable = new sal_uInt8[nSize]; + memset(mpFastColorTable, 0, nSize); for ( pPtr = mpColMap, i = 0; i < mnColors; i++, pPtr += mnCpp + 4 ) { sal_uLong j = pPtr[ 0 ] << 8;
_______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits