Fixes to timeout and delay