Revert "exit instead of break"

This reverts commit 940f54ad7c4fc123416348ffd347d6eee816a630.