[poppler] Branch 'poppler-0.14' - splash/Splash.cc
Albert Astals Cid
aacid at kemper.freedesktop.org
Tue Jun 15 14:58:17 PDT 2010
splash/Splash.cc | 6 ++++++
1 file changed, 6 insertions(+)
New commits:
commit 288ca37b907d6dfaee9bff244bb591429558d8f5
Author: Albert Astals Cid <aacid at kde.org>
Date: Tue Jun 15 22:54:34 2010 +0100
Protect us against negative y coordinates
Happens very rarely, like in bug 28480
diff --git a/splash/Splash.cc b/splash/Splash.cc
index 8b11583..bea4706 100644
--- a/splash/Splash.cc
+++ b/splash/Splash.cc
@@ -42,6 +42,9 @@
#include "SplashGlyphBitmap.h"
#include "Splash.h"
+// to get the unlikely definition
+#include "Object.h"
+
//------------------------------------------------------------------------
// distance of Bezier control point from center for circle approximation
@@ -646,6 +649,9 @@ inline void Splash::pipeIncX(SplashPipe *pipe) {
}
inline void Splash::drawPixel(SplashPipe *pipe, int x, int y, GBool noClip) {
+ if (unlikely(y < 0))
+ return;
+
if (noClip || state->clip->test(x, y)) {
pipeSetXY(pipe, x, y);
pipeRun(pipe);
More information about the poppler
mailing list