vcl/source/outdev/textline.cxx |    7 +++----
 1 file changed, 3 insertions(+), 4 deletions(-)

New commits:
commit 4cac132f3dfa1504d5752cb4fbb8a02d619b7bce
Author:     Caolán McNamara <[email protected]>
AuthorDate: Mon Dec 22 16:21:47 2025 +0000
Commit:     Caolán McNamara <[email protected]>
CommitDate: Mon Dec 22 22:25:53 2025 +0100

    ofz#470601317 Timeout
    
    Change-Id: I50a673dba9572f25f8d40d4a9d3938dae07d6ff9
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/196105
    Reviewed-by: Caolán McNamara <[email protected]>
    Tested-by: Jenkins

diff --git a/vcl/source/outdev/textline.cxx b/vcl/source/outdev/textline.cxx
index 4f54dbbcd3e0..dc8af5d042e9 100644
--- a/vcl/source/outdev/textline.cxx
+++ b/vcl/source/outdev/textline.cxx
@@ -249,8 +249,7 @@ void OutputDevice::ImplDrawWaveLine( tools::Long nBaseX, 
tools::Long nBaseY,
         else
         {
             nCurY += nDiffY;
-            tools::Long nFreq = nCount / (nDiffX+nDiffY);
-            while ( nFreq-- )
+            for (tools::Long nFreq = nCount / (nDiffX+nDiffY); nFreq > 0; 
--nFreq)
             {
                 for( tools::Long i = nDiffY; i; --i )
                 {
@@ -269,8 +268,8 @@ void OutputDevice::ImplDrawWaveLine( tools::Long nBaseX, 
tools::Long nBaseY,
                 }
                 nOffY = -nOffY;
             }
-            nFreq = nCount % (nDiffX+nDiffY);
-            if ( nFreq )
+            tools::Long nFreq = nCount % (nDiffX+nDiffY);
+            if (nFreq > 0)
             {
                 for( tools::Long i = nDiffY; i && nFreq; --i, --nFreq )
                 {

Reply via email to