diff options
author | Albert Astals Cid <aacid@kde.org> | 2015-03-26 15:44:40 +0100 |
---|---|---|
committer | Albert Astals Cid <aacid@kde.org> | 2015-03-26 15:44:40 +0100 |
commit | ede6d00688fcf0e3c843b0a507304f5a98395d41 (patch) | |
tree | cac95489521f8af570a36f80654c03e904642fa5 /poppler/SplashOutputDev.cc | |
parent | 4bb2c9b98299f429752b4c60820cea31ef05f7e0 (diff) |
memset on error to have reproducible outputs
Diffstat (limited to 'poppler/SplashOutputDev.cc')
-rw-r--r-- | poppler/SplashOutputDev.cc | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/poppler/SplashOutputDev.cc b/poppler/SplashOutputDev.cc index 455c2be6..7ad4d448 100644 --- a/poppler/SplashOutputDev.cc +++ b/poppler/SplashOutputDev.cc @@ -2831,14 +2831,15 @@ GBool SplashOutputDev::imageSrc(void *data, SplashColorPtr colorLine, #endif int nComps, x; + nComps = imgData->colorMap->getNumPixelComps(); if (imgData->y == imgData->height) { return gFalse; } if (!(p = imgData->imgStr->getLine())) { + memset(colorLine, 0, imgData->width * nComps); return gFalse; } - nComps = imgData->colorMap->getNumPixelComps(); if (imgData->lookup) { switch (imgData->colorMode) { |