From cf5d4df78af709d0b2aefe546dd0ade3a551da20 Mon Sep 17 00:00:00 2001 From: aris-kimi Date: Thu, 12 Jun 2025 03:07:38 +0300 Subject: [PATCH] Sim:Fix an unescaped while loop --- common/widgets/mathplot.cpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/common/widgets/mathplot.cpp b/common/widgets/mathplot.cpp index 5a8f498457..bf0badfc1d 100644 --- a/common/widgets/mathplot.cpp +++ b/common/widgets/mathplot.cpp @@ -1006,6 +1006,9 @@ void mpScaleXLog::recalculateTicks( wxDC& dc, mpWindow& w ) { step *= 10.0; visibleDecades = log( maxVvis / minVvis ) / log( step ); + + if( !std::isfinite( visibleDecades ) ) + break; } for( d = minDecade; d<=maxDecade; d *= step )