X-Recipient: archive-cygwin AT delorie DOT com DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 0B6EA3858413 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cygwin.com; s=default; t=1693093351; bh=5phRr7+EYRDssS5dIEDAz/SbciBRVG54QLY46PrfZXs=; h=Date:To:Subject:In-Reply-To:References:List-Id:List-Unsubscribe: List-Archive:List-Post:List-Help:List-Subscribe:From:Reply-To: From; b=kYJDcIMSL1C2njKXj24B8oMBEchau1vfl4ibK3L7kLFZ0idLXqun2WaWssGXzEZwM ocUGpYiTtXn4gDzI6Xl9P8nZ4nC0w1/atOoN9w1eGpY/GpjM74J4DSGce1sg2GeYwr 2crf8teaPSKGeJLsk/t6qbzKtLAJBJoFMmfFebAs= X-Original-To: cygwin AT cygwin DOT com Delivered-To: cygwin AT cygwin DOT com DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 160063858D39 Date: Sun, 27 Aug 2023 08:41:36 +0900 To: cygwin AT cygwin DOT com Subject: Re: [EXTERNAL] Re: scp stalls on uploading in cygwin 3.5 current master. Message-Id: <20230827084136.3f6ecbfec6aee89508ecb079@nifty.ne.jp> In-Reply-To: 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> <20230826042924 DOT 53b49a9f8372a9196a151425 AT nifty DOT ne DOT jp> X-Mailer: Sylpheed 3.7.0 (GTK+ 2.24.30; i686-pc-mingw32) Mime-Version: 1.0 X-Spam-Status: No, score=-4.2 required=5.0 tests=BAYES_00, KAM_DMARC_STATUS, NICE_REPLY_A, RCVD_IN_DNSWL_NONE, SPF_HELO_PASS, SPF_PASS, TXREP autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org 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: Takashi Yano via Cygwin Reply-To: Takashi Yano 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 Sat, 26 Aug 2023 14:08:34 +0000 "Lavrentiev, Anton (NIH/NLM/NCBI) [C]" wrote: > IMO you're triggering an undefined (or not well-defined) behavior, because of the murky status > of the byte count of 0. It may work now, but it may not work in the future... > > RETURN VALUE > On success, the number of bytes written is returned (zero indicates nothing was written). On error, -1 is returned, and > errno is set appropriately. > > If count is zero and fd refers to a regular file, then write() may return a failure status if one of the errors below is > detected. If no errors are detected, 0 will be returned without causing any other effect. If count is zero and fd refers > to a file other than a regular file, the results are not specified. You seems to reffer Linux man, however, this patch calls ssize_t fhandler_socket_wsock::write (const void *in_ptr, size_t len) of cygwin, NOT Linux write(). -- Takashi Yano -- 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