$OpenBSD: patch-poppler_SplashOutputDev_cc,v 1.1 2011/03/03 21:25:38 stsp Exp $ Upstream commit 37077aa475d2dee81f87daa05297b201eeb99c87. Fixes a heap overflow. --- poppler/SplashOutputDev.cc.orig Sat Feb 19 15:18:31 2011 +++ poppler/SplashOutputDev.cc Sat Feb 19 15:19:20 2011 @@ -2881,14 +2881,14 @@ void SplashOutputDev::beginTransparencyGroup(GfxState tx = (int)floor(xMin); if (tx < 0) { tx = 0; - } else if (tx > bitmap->getWidth()) { - tx = bitmap->getWidth(); + } else if (tx >= bitmap->getWidth()) { + tx = bitmap->getWidth() - 1; } ty = (int)floor(yMin); if (ty < 0) { ty = 0; - } else if (ty > bitmap->getHeight()) { - ty = bitmap->getHeight(); + } else if (ty >= bitmap->getHeight()) { + ty = bitmap->getHeight() - 1; } w = (int)ceil(xMax) - tx + 1; if (tx + w > bitmap->getWidth()) {