From 0f7819e47221b24b22ef440f9bdad6d377721254 Mon Sep 17 00:00:00 2001 From: daid Date: Mon, 26 Aug 2013 16:02:43 +0200 Subject: [PATCH] Make sure you cannot get a division by zero exception. --- Cura/util/profile.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Cura/util/profile.py b/Cura/util/profile.py index 90f32b41..a886f1d1 100644 --- a/Cura/util/profile.py +++ b/Cura/util/profile.py @@ -660,6 +660,8 @@ def calculateLineCount(): return 1 lineCount = int(wallThickness / (nozzleSize - 0.0001)) + if lineCount < 1: + lineCount = 1 lineWidth = wallThickness / lineCount lineWidthAlt = wallThickness / (lineCount + 1) if lineWidth > nozzleSize * 1.5: -- 2.30.2