Message-ID: <3a2e12d0-705f-4ee3-d892-25eb7fa33ef5@...68...> Date: Thu, 18 May 2023 09:12:02 +0200 MIME-Version: 1.0 Content-Language: en-US References: <20230517200143.216-1-chipitsine@...277...> From: Matthias Andree In-Reply-To: Subject: Re: [Openvpn-devel] [PATCH] src/openvpn/dco_freebsd.c: handle malloc failure List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit To: openvpn-devel@lists.sourceforge.net Am 18.05.23 um 09:09 schrieb Gert Doering: > Hi, > > On Thu, May 18, 2023 at 09:00:26AM +0200, Matthias Andree wrote: >> That, and constants usually go on the left-hand side of comparison so >> the compiler flags the accidental if (foo = NULL) even if it does not >> produce "add a pair of parentheses if you really mean to use an >> assignment as if() expression" like warnings. You can't if (NULL = foo)... > This is actually not OpenVPN style today (it's "syzzer style" so we find > it in a few crypto modules). I personally find if (B) or if (!B) more concise and clearer, too.