Better timeout handling