diff --git a/runtime/src/main/java/com/dylibso/chicory/runtime/Machine.java b/runtime/src/main/java/com/dylibso/chicory/runtime/Machine.java index f4035b3ef..251f4996c 100644 --- a/runtime/src/main/java/com/dylibso/chicory/runtime/Machine.java +++ b/runtime/src/main/java/com/dylibso/chicory/runtime/Machine.java @@ -764,7 +764,7 @@ void eval(List code) throws ChicoryException { } } } catch (ArithmeticException e) { - if (e.getMessage().toLowerCase().equals("/ by zero")) { + if (e.getMessage().equalsIgnoreCase("/ by zero")) { throw new WASMRuntimeException("integer divide by zero"); } throw new WASMRuntimeException(e.getMessage());