From 8ca3dfcdfa5d25edc8ccee5016ac14d10bd5aa86 Mon Sep 17 00:00:00 2001 From: Julian Smart Date: Wed, 4 Jun 2003 12:53:03 +0000 Subject: [PATCH] Don't divide by zero. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@20921 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- contrib/src/fl/rowlayoutpl.cpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/contrib/src/fl/rowlayoutpl.cpp b/contrib/src/fl/rowlayoutpl.cpp index a1dd955c8c..92af22e862 100644 --- a/contrib/src/fl/rowlayoutpl.cpp +++ b/contrib/src/fl/rowlayoutpl.cpp @@ -433,6 +433,9 @@ void cbRowLayoutPlugin::ApplyLengthRatios( cbRowInfo* pRow ) // look like total of mLetRatio's is 1.0, thus original // len. ratios are _preserved_: + if (pcntSum == 0.0) + pcntSum = 1.0; + double unit = freeSpc / pcntSum; bool haveSquished = FALSE; -- 2.47.2