Fix Illegal division by zero at line 3832. Thanks to MarcoTrek for the report.