X-Recipient: archive-cygwin@delorie.com
X-Spam-Check-By: sourceware.org
Date: Wed, 28 Nov 2007 10:48:44 +0100
From: Corinna Vinschen <corinna-cygwin@cygwin.com>
To: cygwin@cygwin.com
Subject: Re: socket : MSG_WAITALL isn't defined
Message-ID: <20071128094844.GB30894@calimero.vinschen.de>
Reply-To: cygwin@cygwin.com
Mail-Followup-To: cygwin@cygwin.com
References: <474D1966.8040304@prologue.fr>
MIME-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
In-Reply-To: <474D1966.8040304@prologue.fr>
User-Agent: Mutt/1.5.16 (2007-06-09)
Mailing-List: contact cygwin-help@cygwin.com; run by ezmlm
Precedence: bulk
List-Id: <cygwin.cygwin.com>
List-Unsubscribe: <mailto:cygwin-unsubscribe-archive-cygwin=delorie.com@cygwin.com>
List-Subscribe: <mailto:cygwin-subscribe@cygwin.com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin@cygwin.com>
List-Help: <mailto:cygwin-help@cygwin.com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner@cygwin.com
Mail-Followup-To: cygwin@cygwin.com
Delivered-To: mailing list cygwin@cygwin.com

On Nov 28 08:31, patrick ficheux wrote:
> Hi,
>
> I want to use recv() with MSG_WAITALL flag. But this constant isn't defined 
> in cygwin.
> I find a old message about this issue here => 
> http://www.cygwin.com/ml/cygwin/2000-06/msg01229.html
>
> Why MSG_WAITALL is not present in cygwin ?
> It's a posix compliance problem ?

No, it's a Winsock compliance problem.  Actually the MSG_WAITALL flag
showed up for the first time in Windows 2003 Server.  So, if you rely on
this flag, your application might break when running on any earlier
Windows version up to and including Windows XP.

There are also no considerations in Cygwin's recv implementation to
emulate the MSG_WAITALL behaviour.  I put that on my TODO list for a
later Cygwin version, though.  For now you're better off with a recv
loop in your application which ensures that the right number of bytes
are read.


Corinna

-- 
Corinna Vinschen                  Please, send mails regarding Cygwin to
Cygwin Project Co-Leader          cygwin AT cygwin DOT com
Red Hat

--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Problem reports:       http://cygwin.com/problems.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/

