From: "flichtenheld (Code Review)" Date: Sat, 4 Apr 2026 16:33:41 +0000 References: Reply-To: frank@...2641..., arne-openvpn@...1227..., openvpn-devel@lists.sourceforge.net Message-ID: <0e174109857f11d8c12aeb8cc621261370ecc17b-HTML@...2715...> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Disposition: inline Content-Type: multipart/alternative; boundary="9mWNHmT7BGg="; charset=UTF-8 Subject: [Openvpn-devel] [XS] Change in openvpn[master]: win: Fix nrpt_dnssec flag handling List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: plaisthos Cc: openvpn-devel --9mWNHmT7BGg= Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Attention is currently required from: plaisthos. Hello plaisthos, I'd like you to do a code review. Please visit http://gerrit.openvpn.net/c/openvpn/+/1606?usp=3Demail to review the following change. Change subject: win: Fix nrpt_dnssec flag handling ...................................................................... win: Fix nrpt_dnssec flag handling By default the first enum value is 0. But we check whether we set the flag by doing BOOL dnssec =3D (msg->flags & nrpt_dnssec) !=3D 0; This can't ever be true. Found by cppcheck. Change-Id: Iff5be978817bfc0cd4d78818e7be7b90bad71f3c Signed-off-by: Frank Lichtenheld --- M include/openvpn-msg.h 1 file changed, 1 insertion(+), 1 deletion(-) git pull ssh://gerrit.openvpn.net:29418/openvpn refs/changes/06/1606/1 diff --git a/include/openvpn-msg.h b/include/openvpn-msg.h index bef20cf..ca3267e 100644 --- a/include/openvpn-msg.h +++ b/include/openvpn-msg.h @@ -110,7 +110,7 @@ typedef enum { - nrpt_dnssec + nrpt_dnssec =3D 1 << 0, } nrpt_flags_t; #define NRPT_ADDR_NUM 8 /* Max. number of addresses */ -- To view, visit http://gerrit.openvpn.net/c/openvpn/+/1606?usp=3Demail To unsubscribe, or for help writing mail filters, visit http://gerrit.openv= pn.net/settings?usp=3Demail Gerrit-MessageType: newchange Gerrit-Project: openvpn Gerrit-Branch: master Gerrit-Change-Id: Iff5be978817bfc0cd4d78818e7be7b90bad71f3c Gerrit-Change-Number: 1606 Gerrit-PatchSet: 1 Gerrit-Owner: flichtenheld Gerrit-Reviewer: plaisthos Gerrit-CC: openvpn-devel Gerrit-Attention: plaisthos --9mWNHmT7BGg= Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable

Attention is cur= rently required from: plaisthos.

flichtenheld would like plaisthos to review this change.

V= iew Change

win: Fix nrpt_dnssec flag handling

B= y default the first enum value is 0.
But we check whether we set the fla= g by doing
BOOL dnssec =3D (msg->flags & nrpt_dnssec) !=3D 0;
= This can't ever be true.

Found by cppcheck.

Change-Id: If= f5be978817bfc0cd4d78818e7be7b90bad71f3c
Signed-off-by: Frank Lichtenheld= <frank@...2641...>
---
M include/openvpn-msg.h
1 file chang= ed, 1 insertion(+), 1 deletion(-)

git pull ssh:=
//gerrit.openvpn.net:29418/openvpn refs/changes/06/1606/1
diff --=
git a/include/openvpn-msg.h b/include/openvpn-msg.h
index b= ef20cf..ca3267e 100644
--- a/include/openvpn-msg.h+++ b/include/openvpn-msg.h
@@ -110,7 +110,7 @@

typedef enum
{
<= span style=3D"color: hsl(0, 100%, 40%);">- nrpt_dnssec

+ nrpt_dnssec =3D 1 << 0,
} nrpt_flags_t;

#define NR= PT_ADDR_NUM 8 /* Max. number of addresses */

<= /pre>

To view, visit change 1606. To unsubscribe, or for help writing mail fi= lters, visit set= tings.

=
Gerrit-MessageType: newchange
Gerrit-Project: openvpn
Gerrit-Branch: master
Gerrit-Change-Id: Iff5be978817bfc0cd4d78818e7b= e7b90bad71f3c
Gerrit-Change-Number: 1606
Gerrit-PatchSet: 1
Gerrit-Owner: flichtenheld <frank@...2723...= .>
Gerrit-Reviewer: plaisthos <arne-openvpn@...1186...= .1227...>
Gerrit-CC: openvpn-devel <openvpn-devel@...1484...= ts.sourceforge.net>
Gerrit-Attention: plaisthos <arne-openvpn@...220...= ..1227...>
= --9mWNHmT7BGg=--