X-Recipient: archive-cygwin AT delorie DOT com DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 1256C3858291 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cygwin.com; s=default; t=1693057983; bh=lxrCS9WzKv/FK3SQb+IpArTAXw82pdiqS8nGBHw8eWw=; h=Date:To:Subject:References:In-Reply-To:List-Id:List-Unsubscribe: List-Archive:List-Post:List-Help:List-Subscribe:From:Reply-To:Cc: From; b=VpMKw8oT5GAN9CSnJD7f71vNuYuGfunTG0SewEA4Kc9wNsuQNCL/eHzOL5QKDKjw7 oc/aC/7pfIoVW/gVeEw8nZiHRykPEXD8BgziOQQFZHOpL7wDnNtYz3ns7pFiidNTMV T3r9vD0mP8V7COTO3c9Aa6T0ax0dPmciBZK7E4X0= X-Original-To: cygwin AT cygwin DOT com Delivered-To: cygwin AT cygwin DOT com DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org A00973858C33 Date: Sat, 26 Aug 2023 15:52:05 +0200 To: cygwin AT cygwin DOT com Subject: Re: [EXTERNAL] Re: scp stalls on uploading in cygwin 3.5 current master. Message-ID: Mail-Followup-To: cygwin AT cygwin DOT com References: <20230824060502 DOT c4798062cb19d4d35a5633ae AT nifty DOT ne DOT jp> <20230824123131 DOT 390b4471915c963425c77608 AT nifty DOT ne DOT jp> <20230825174832 DOT 9ebae8112667d5d5411cb8db AT nifty DOT ne DOT jp> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: X-BeenThere: cygwin AT cygwin DOT com X-Mailman-Version: 2.1.29 Precedence: list List-Id: General Cygwin discussions and problem reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , From: Corinna Vinschen via Cygwin Reply-To: cygwin AT cygwin DOT com Cc: Corinna Vinschen Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Errors-To: cygwin-bounces+archive-cygwin=delorie DOT com AT cygwin DOT com Sender: "Cygwin" On Aug 25 23:27, Lavrentiev, Anton (NIH/NLM/NCBI) [C] via Cygwin wrote: > > While select indicates that > > data can be written, it doesn't indicate how much data can be written. > > I. e., if select returns, and there's only buffer space for 10 bytes, > > and the send call tries to send 100 bytes, it *will* block, unless the > > socket is non-blocking and returns EAGAIN. > > IIRC, if there's space for 10 bytes in the internal buffer, send(100) > will return 10, whether or not the socket is blocking. It doesn't, afaics. It raises the buffer size until something a bit less than 512K and then it starts blocking. > EAGAIN is only returned when nothing at all can be written to a > non-blocking socket; or send() blocks (when blocking). This thread is not about send() blocking or returning EAGAIN. This is about the behaviour of select(2) and poll(2). Corinna -- Problem reports: https://cygwin.com/problems.html FAQ: https://cygwin.com/faq/ Documentation: https://cygwin.com/docs.html Unsubscribe info: https://cygwin.com/ml/#unsubscribe-simple