Add missing break and continue statements

* With thanks to tommythorn