conn: fix io.EOF bug, thank @Jesse