Don't crash with runtime exception
This commit is contained in:
parent
c09d7d6bf5
commit
636800178c
@ -197,6 +197,8 @@ public class Calculator implements SharedPreferences.OnSharedPreferenceChangeLis
|
|||||||
bus.post(new CalculationCancelledEvent(o, e, sequence));
|
bus.post(new CalculationCancelledEvent(o, e, sequence));
|
||||||
} catch (ParseException exception) {
|
} catch (ParseException exception) {
|
||||||
onException(sequence, o, e, mr, pe, exception);
|
onException(sequence, o, e, mr, pe, exception);
|
||||||
|
} catch (RuntimeException exception) {
|
||||||
|
onException(sequence, o, e, mr, pe, new ParseException(e, new CalculatorMessage(CalculatorMessages.syntax_error, MessageType.error)));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user