From patchwork Thu Nov 19 21:26:17 2026 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Gert Doering X-Patchwork-Id: 5752 Return-Path: Delivered-To: patchwork@openvpn.net Received: by 2002:a05:6022:231a:b0:11b:d6c:f273 with SMTP id cr26csp601549lab; Thu, 19 Nov 2026 13:26:33 -0800 (PST) X-Forwarded-Encrypted: i=2; AL+hErGhvdegSzH18aeq7rsPjCRMZkdL9Uh5CoWi3StLT6AZCPRAc2E3PEMnH3fYCo7dK5wCdd8Mp96tiPc=@openvpn.net X-Received: by 2002:a05:6808:e90:b0:4f3:e98f:fa19 with SMTP id 5614622812f47-57a0c4b90eamr1454889b6e.61.1795123593434; Thu, 19 Nov 2026 13:26:33 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1795123593; cv=none; d=google.com; s=arc-20260327; b=oa7OGWXE4xTns/hDeHP6ReTdXZlXHiMLVz3yz95DIIE7jDH+/M8ATXF1Ly830WiJmY QKbuDru3LAg6uGTk7oHxMt7NHItaIVAwG0qfZqD0dUswaLRNVv+fwtpFJFdhV9Qib9JP wy+v9xWIIcmQiSmz0W0lGoQ+tr3F8C1Xg0Cipeun+kIZat6hJXegrWKwbCTWaV4+Mtz8 wMQEzXw7cSyaXKOUyvvDdXtik/DhILOnQTR2shymFwWvhcn3D1+BHsZ9yA2WVq5IK2Kc /C7cq/27QdJ2YXAuvgDL3pZ98wlb6YMQjlsyO8I877oYf7OueOmNmPp2pPUnmywWQ7Im s1Ew== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20260327; h=errors-to:content-transfer-encoding:list-subscribe:list-help :list-post:list-archive:list-unsubscribe:list-id:precedence:subject :mime-version:references:in-reply-to:message-id:date:to:from :dkim-signature:dkim-signature:dkim-signature; bh=5O19HiSHXKEg2v8GPvNeBYagc8AuNCx5CK3jiRzJ7cU=; fh=4NbAC/LsuMLI0S0hprUlLSLCiHwg6SCAifhH718Jh0Q=; b=mnVGxbjQsClohl66J4OnMGNrp2AbTpxsWy4GJXWHBrpE4Q49dXoiYiFzBrmEUg+4Mu VDDdKvwpmeVnWS3SVDofSJrl5d4ZcH/C/iwZct5YhO3bPVTh4N7KazDrZ82xGsg5jmbg JaFzJilt8abD8u8DBZDyk0BDda6l/N907gIFqAvfkSTYUr7cebxkz6BVAVuap6j0bKto 3uNUPkkwJLQG1GdYGdd/hBMhSuieaC418RJ+rUhzhaLh+txry7iTjci+lwrFFR/vvWAc /bsb1+0nIXmceV2GN7yAvZpsYmaKlvTy1AS8tPqgmHsoRWcSMNNGgOa4IPBwpGA0Zpeb Fvww==; dara=google.com ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@lists.sourceforge.net header.s=beta header.b=Lk7eyrtM; dkim=neutral (body hash did not verify) header.i=@sourceforge.net header.s=x header.b=ehw+YutD; dkim=neutral (body hash did not verify) header.i=@sf.net header.s=x header.b=DIuxNqHg; spf=pass (google.com: domain of openvpn-devel-bounces@lists.sourceforge.net designates 216.105.38.7 as permitted sender) smtp.mailfrom=openvpn-devel-bounces@lists.sourceforge.net; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=muc.de Received: from lists.sourceforge.net (lists.sourceforge.net. [216.105.38.7]) by mx.google.com with ESMTPS id 5614622812f47-57a3132cbacsi1078582b6e.9.2026.11.19.13.26.33 (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Thu, 19 Nov 2026 13:26:33 -0800 (PST) Received-SPF: pass (google.com: domain of openvpn-devel-bounces@lists.sourceforge.net designates 216.105.38.7 as permitted sender) client-ip=216.105.38.7; Authentication-Results: mx.google.com; dkim=pass header.i=@lists.sourceforge.net header.s=beta header.b=Lk7eyrtM; dkim=neutral (body hash did not verify) header.i=@sourceforge.net header.s=x header.b=ehw+YutD; dkim=neutral (body hash did not verify) header.i=@sf.net header.s=x header.b=DIuxNqHg; spf=pass (google.com: domain of openvpn-devel-bounces@lists.sourceforge.net designates 216.105.38.7 as permitted sender) smtp.mailfrom=openvpn-devel-bounces@lists.sourceforge.net; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=muc.de DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.sourceforge.net; s=beta; h=Content-Transfer-Encoding:Content-Type: List-Subscribe:List-Help:List-Post:List-Archive:List-Unsubscribe:List-Id: Subject:MIME-Version:References:In-Reply-To:Message-ID:Date:To:From:Sender: Reply-To:Cc:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Unsubscribe-Post: List-Owner; bh=5O19HiSHXKEg2v8GPvNeBYagc8AuNCx5CK3jiRzJ7cU=; b=Lk7eyrtMisdxYD nW3QjlFwLtQSK702PkaltaL3zhM4eguYMRoTHSZx4wMDH132FlgfhbeuSkVp+1hiDZ21q8IGkMzA3 w4KhbsQxU75AxxQKli00KGaexYuxZJam65JEeDMeRiRClF8HFNuRKlmH31MbbzlXXuA7XFnZXHlO2 X2s=; Received: from [127.0.0.1] (helo=sfs-ml-1.v29.lw.sourceforge.com) by sfs-ml-1.v29.lw.sourceforge.com with esmtp (Exim 4.100.1) (envelope-from ) id 1xU9eK-000000006NC-17ND; Thu, 19 Nov 2026 21:26:32 +0000 Received: from [172.30.29.66] (helo=mx.sourceforge.net) by sfs-ml-1.v29.lw.sourceforge.com with esmtps (TLS1.2) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.100.1) (envelope-from ) id 1xU9eJ-000000006N6-0iCj for openvpn-devel@lists.sourceforge.net; Thu, 19 Nov 2026 21:26:31 +0000 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=sourceforge.net; s=x; h=Content-Transfer-Encoding:MIME-Version:References: In-Reply-To:Message-ID:Date:Subject:To:From:Sender:Reply-To:Cc:Content-Type: Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender: Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help:List-Unsubscribe: List-Unsubscribe-Post:List-Subscribe:List-Post:List-Owner:List-Archive; bh=dRqW/FK6rFNOXVKNEONqUP8qdQrzDLo12dSa9o2os+I=; b=ehw+YutDfdplnlFNaSWcZxjsak pwaZqP2R1+wEE01iYcXnO3FSGU/Y7Risz+JBUxk/SFwnvmPhsSQ7lLhiEAfVhjjJ/cS5nW18NeqMY zVBLMuMfc8mU7k9qOeJRLyE34r7ZJqNS2fbDjNjz984JI9qNc8CcTQELD9AmE6a83z+U=; DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=sf.net; s=x ; h=Content-Transfer-Encoding:MIME-Version:References:In-Reply-To:Message-ID: Date:Subject:To:From:Sender:Reply-To:Cc:Content-Type:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:List-Id:List-Help:List-Unsubscribe:List-Unsubscribe-Post: List-Subscribe:List-Post:List-Owner:List-Archive; bh=dRqW/FK6rFNOXVKNEONqUP8qdQrzDLo12dSa9o2os+I=; b=DIuxNqHg1dg/cRZF/nHZngG/N2 fPd/QBBIxyKTFBTUGUNbKaXAb3qtso99EzajDsEvgTAJ5H4hL69kXYZ7b8+UY1CbeS8CH+sItdh5T pEBmK+hC20OUUuHNAG7slUVZnma7mVKet3CERH82i279bBSzEVqLbLqKHSSykN/8GYdk=; Received: from [193.149.48.129] (helo=blue.greenie.muc.de) by sfi-mx-2.v28.lw.sourceforge.com with esmtps (TLS1.2:ECDHE-RSA-AES256-GCM-SHA384:256) (Exim 4.100.1) id 1xU9eH-000000004R6-1hDH for openvpn-devel@lists.sourceforge.net; Thu, 19 Nov 2026 21:26:31 +0000 Received: from blue.greenie.muc.de (localhost [127.0.0.1]) by blue.greenie.muc.de (8.18.1/8.18.1) with ESMTP id 6AJLQMku005865 for ; Thu, 19 Nov 2026 22:26:22 +0100 Received: (from gert@localhost) by blue.greenie.muc.de (8.18.2/8.18.1/Submit) id 6AJLQMDC005864 for openvpn-devel@lists.sourceforge.net; Thu, 19 Nov 2026 22:26:22 +0100 From: Gert Doering To: openvpn-devel@lists.sourceforge.net Date: Thu, 19 Nov 2026 22:26:17 +0100 Message-ID: <20261119212622.5852-1-gert@greenie.muc.de> X-Mailer: git-send-email 2.55.0 In-Reply-To: References: MIME-Version: 1.0 X-Spam-Score: 1.3 (+) X-Spam-Report: Spam detection software, running on the system "sfi-spamd-2.hosts.colo.sdot.me", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see the administrator of that system for details. Content preview: From: Razvan Cojocaru Assigning strstr()'s result to the bool remote_usescomp warns under MSVC and fails the /WX build. Compare against NULL. Change-Id: I9a78e57cff805e1896d79a17fbcd4132c5a4b1b3 Signed-off-by: Razvan Cojocaru Acked-by: Lev Stipakov Gerrit URL: https://gerrit.openvpn.net/c/openvpn/ [...] Content analysis details: (1.3 points, 5.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- 1.3 RDNS_NONE Delivered to internal network by a host with no rDNS X-Headers-End: 1xU9eH-000000004R6-1hDH Subject: [Openvpn-devel] [PATCH v1] ssl: fix MSVC C4047 in key_method_2_read() X-BeenThere: openvpn-devel@lists.sourceforge.net X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: openvpn-devel-bounces@lists.sourceforge.net X-getmail-retrieved-from-mailbox: Inbox X-GMAIL-THRID: 1882323516904980032 X-GMAIL-MSGID: 1882323516904980032 From: Razvan Cojocaru Assigning strstr()'s result to the bool remote_usescomp warns under MSVC and fails the /WX build. Compare against NULL. Change-Id: I9a78e57cff805e1896d79a17fbcd4132c5a4b1b3 Signed-off-by: Razvan Cojocaru Acked-by: Lev Stipakov Gerrit URL: https://gerrit.openvpn.net/c/openvpn/+/2220 --- This change was reviewed on Gerrit and approved by at least one developer. I request to merge it to master. Gerrit URL: https://gerrit.openvpn.net/c/openvpn/+/2220 This mail reflects revision 1 of this Change. Acked-by according to Gerrit (reflected above): Lev Stipakov diff --git a/src/openvpn/ssl.c b/src/openvpn/ssl.c index e06659a..d5ae13d 100644 --- a/src/openvpn/ssl.c +++ b/src/openvpn/ssl.c @@ -2409,7 +2409,7 @@ free(multi->remote_ciphername); multi->remote_ciphername = options_string_extract_option(options, "cipher", NULL); - multi->remote_usescomp = strstr(options, ",comp-lzo,"); + multi->remote_usescomp = (strstr(options, ",comp-lzo,") != NULL); /* In OCC we send '[null-cipher]' instead 'none' */ if (multi->remote_ciphername && strcmp(multi->remote_ciphername, "[null-cipher]") == 0)