From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 7986 invoked by alias); 20 Sep 2006 04:34:53 -0000 Received: (qmail 7976 invoked by uid 22791); 20 Sep 2006 04:34:53 -0000 X-Spam-Check-By: sourceware.org Received: from 62-177-154-238.dsl.bbeyond.nl (HELO lembu.sumatrasoftware.com) (62.177.154.238) by sourceware.org (qpsmtpd/0.31) with ESMTP; Wed, 20 Sep 2006 04:34:50 +0000 Content-class: urn:content-classes:message MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Subject: RE: New SocketChannel test that requires testing Date: Wed, 20 Sep 2006 04:34:00 -0000 Message-ID: In-Reply-To: <45103899.7070400@gnu.org> From: "Jeroen Frijters" To: "Casey Marshall" Cc: X-IsSubscribed: yes Mailing-List: contact mauve-discuss-help@sourceware.org; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: mauve-discuss-owner@sourceware.org X-SW-Source: 2006-q3/txt/msg00031.txt.bz2 Casey Marshall wrote: > > I don't think it has nothing to do with the underlying=20 > > socket mechanics, > > it is simply an invariant of the SocketChannel API. >=20 > Nope: >=20 > "If this channel is in non-blocking mode then an invocation of this > method initiates a non-blocking connection operation. If the=20 > connection is established immediately, as can happen with a local=20 > connection, then this method returns true. Otherwise this method > returns false and the connection operation must later be completed > by invoking the finishConnect method." [1] >=20 > 1. > http://java.sun.com/j2se/1.4.2/docs/api/java/nio/channels/Sock > etChannel.html#connect(java.net.SocketAddress) May be I misunderstood what you meant, we were talking about isConnected() changing its return value right? The only way I can read the text you quoted is that it confirms that isConnected() will only return true iff either connect() or finishConnect() previously returned true. Regards, Jeroen