proctool: add an interval argument to 'wait'