Added timeout for network check.