perl-lib: only call join callbacks if no-one joined
perl-lib: update @timeouts because we may have changed thems