Catch IllegalStateException when scheduling timer.

This appears to be a race condition that I couldn't reproduce. The Timer class doesn't have a way to check if it is canceled or not, so I resorted to catching the exception.

Fixes #157