Do not check the return code on read timeout for bash 4.0+

Is this patch OK?