Should fix second part of issue #336.
Catching division by zero in modulo.