Yes, that's right. Reason is that proc_kill was called before and not after the wait(). Put it after the wait and it will work as expected.

Proc_kill(4) kills all instances of the action currently started by the scheduler. This is only identical to the current action when this action encountered a wait() before. I admit that this can be confusing. I'll check if I can improve this.