vcl/headless/SvpGraphicsBackend.cxx     |    5 +++++
 vcl/inc/headless/SvpGraphicsBackend.hxx |    3 +++
 2 files changed, 8 insertions(+)

New commits:
commit fd4a089df684a38cff18e77217961ee4bee0c497
Author:     Caolán McNamara <[email protected]>
AuthorDate: Sun May 8 15:30:42 2022 +0100
Commit:     Caolán McNamara <[email protected]>
CommitDate: Sun May 8 20:33:58 2022 +0200

    ofz#46607 Integer-overflow
    
    Change-Id: Id759423176b2e47fc00b8e7babd936b480956617
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134025
    Tested-by: Jenkins
    Reviewed-by: Caolán McNamara <[email protected]>

diff --git a/vcl/headless/SvpGraphicsBackend.cxx 
b/vcl/headless/SvpGraphicsBackend.cxx
index 223b333e9bef..14a9a017ed94 100644
--- a/vcl/headless/SvpGraphicsBackend.cxx
+++ b/vcl/headless/SvpGraphicsBackend.cxx
@@ -154,6 +154,11 @@ void SvpGraphicsBackend::drawLine(tools::Long nX1, 
tools::Long nY1, tools::Long
 
 void SvpGraphicsBackend::drawRect(tools::Long nX, tools::Long nY, tools::Long 
nWidth,
                                   tools::Long nHeight)
+{
+    implDrawRect(nX, nY, nWidth, nHeight);
+}
+
+void SvpGraphicsBackend::implDrawRect(double nX, double nY, double nWidth, 
double nHeight)
 {
     // because of the -1 hack we have to do fill and draw separately
     Color aOrigFillColor = m_rCairoCommon.m_aFillColor;
diff --git a/vcl/inc/headless/SvpGraphicsBackend.hxx 
b/vcl/inc/headless/SvpGraphicsBackend.hxx
index 16f9213576fd..997f1bc84e9d 100644
--- a/vcl/inc/headless/SvpGraphicsBackend.hxx
+++ b/vcl/inc/headless/SvpGraphicsBackend.hxx
@@ -134,6 +134,9 @@ public:
 
     void drawBitmapBuffer(const SalTwoRect& rPosAry, const BitmapBuffer* 
pBuffer,
                           cairo_operator_t eOp);
+
+private:
+    void implDrawRect(double nX, double nY, double nWidth, double nHeight);
 };
 
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */

Reply via email to