[poppler] splash/Splash.cc

GitLab Mirror gitlab-mirror at kemper.freedesktop.org
Fri Dec 2 22:02:21 UTC 2022


 splash/Splash.cc |    3 +++
 1 file changed, 3 insertions(+)

New commits:
commit 2944c16a1ac7da0aaf9cb351ff664585968d8356
Author: Albert Astals Cid <aacid at kde.org>
Date:   Fri Dec 2 22:55:51 2022 +0100

    Fix crash on broken documents
    
    Issue #1320

diff --git a/splash/Splash.cc b/splash/Splash.cc
index 05f000d9..0dbd0c0e 100644
--- a/splash/Splash.cc
+++ b/splash/Splash.cc
@@ -3892,6 +3892,9 @@ SplashError Splash::arbitraryTransformImage(SplashImageSource src, SplashICCTran
             if (xa == xb) {
                 ++xb;
             }
+            if (unlikely(clipRes == splashClipAllInside && xb > bitmap->getWidth())) {
+                xb = bitmap->getWidth();
+            }
             if (clipRes != splashClipAllInside) {
                 clipRes2 = state->clip->testSpan(xa, xb - 1, y);
             } else {


More information about the poppler mailing list