From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mout.gmx.net (mout.gmx.net [212.227.17.22]) by sourceware.org (Postfix) with ESMTPS id 059CC3850434 for ; Wed, 8 Sep 2021 06:14:46 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org 059CC3850434 X-UI-Sender-Class: 01bb95c1-4bf8-414a-932a-4f6e2808ef9c Received: from [192.168.15.104] ([88.97.26.74]) by mail.gmx.net (mrgmx105 [212.227.17.174]) with ESMTPSA (Nemesis) id 1MQv8x-1mct862QCN-00NyPL for ; Wed, 08 Sep 2021 08:14:45 +0200 Subject: Re: mmap failure [was: cygrunsrv + sshd + rsync = 20 times too slow -- throttled?] To: cygwin@cygwin.com References: <88fde5d5-4897-8792-576a-a62be0092ad8@cornell.edu> <94b5b6cf-1670-cbdd-2f51-84dae09d27b6@cornell.edu> <387d9062-1ff9-6eab-e268-e5070352a193@cornell.edu> <40275f71-7c10-55a9-e6c8-a948e32c37ac@cornell.edu> <33ae27cb-4e45-7484-40d1-6cbd88c958f1@cornell.edu> <3a63eb8c-3e8e-cd2c-b9de-8c34fa041a75@cornell.edu> <5b705ae7c9747a9cc25d2610cc6748e92bbe1d70.camel@dontech.dk> <890dad21-dec5-cdd1-bf99-bdb45e759a71@cornell.edu> <742331ee-4d9f-e86f-9314-c85b5f0cbfa8@SystematicSw.ab.ca> <3bb3814c-0584-c918-6710-f71c7abfbcc5@cornell.edu> <07cb816c-0bca-440d-338d-fefb110d4a41@cornell.edu> From: Sam Edge Message-ID: <387bef5e-1352-daef-b9c2-bfc761d442ee@gmx.com> Date: Wed, 8 Sep 2021 07:14:45 +0100 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:78.0) Gecko/20100101 Thunderbird/78.14.0 MIME-Version: 1.0 In-Reply-To: <07cb816c-0bca-440d-338d-fefb110d4a41@cornell.edu> Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: quoted-printable Content-Language: en-GB X-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YqTMa3sijF8AizF6HQhlxRIR bJsns/sXVthvfW9C8gLGwOEUbL7VWjEFBTT3wCCDbi1J9xPAXsoaLu7su3p4il+CaYgHt37O/ uHrP4FazInv/kaFjkZM4IpRpeXpSXggcrM52ZwQwQqYVQU6RU9aDxkDY8FMPpyyxy0NGKm8JY XNIK67BT3KZ/Hnp8gMvcctI2q422NlR1tiBfO7LLEQQ59PcUKNe3TiOnn8RVNKglaNBz+yDGV 1F0DohrufvsY1yznLRDGIRJRQR/te3XimjNFHUzIR3mV4xl6G/mORl7NsTrxtzkG2evW7NGoB CpeQZwOYTIzUBOWfSpZyBt6I1vWs4wNqhRoBm5X4W5Nt73H0jnNkX4dbw== X-Spam-Status: No, score=-4.2 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, FREEMAIL_FROM, NICE_REPLY_A, RCVD_IN_MSPIKE_H3, RCVD_IN_MSPIKE_WL, SPF_HELO_NONE, SPF_PASS, TXREP autolearn=ham autolearn_force=no version=3.4.4 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on server2.sourceware.org X-BeenThere: cygwin@cygwin.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: , X-List-Received-Date: Wed, 08 Sep 2021 06:14:48 -0000 On 07/09/2021 23:44, Ken Brown via Cygwin wrote: > > MS can't add a new named field to a documented struct without breaking a lot of code.=C2=A0 I think it's extremely unlikely that they wo= uld do that.=C2=A0 On the other hand, I think it's very likely that a reader o= f the Cygwin code would be confused by code that initializes a struct to 0 prior to assigning a value to every member. Hi Ken. It is common practice when following a coding standard (especially those for safety or security sensitive code) to initialize each and every automatic C/C++ variable at the point of definition even if it is later assigned a value. The '=3D {0}' mechanism for structures is a common way of ensuring this is the case for all fields in a structure and should be familiar to most developers. This ensures deterministic behaviour instead of bugs that come and go depending upon what was on the stack or in the register before the variable is used. It also helps when reviewing code. A compiler or static analyser cannot always determine whether a variable is used before it's assigned so getting into the habit of doing this saves a lot of grief down the line, as demonstrated by this thread! =2D- Sam "Here Endeth The Lesson" Edge