Fix scheduler bug where adding events during another event's callback
caused a segfault.
Add four more patterns.