From: "cron2 (Code Review)" Date: Thu, 11 Sep 2025 17:39:44 +0000 In-Reply-To: References: Reply-To: gert@...1296..., arne-openvpn@...1227..., openvpn-devel@lists.sourceforge.net, frank@...2641..., antonio@...2726... Message-ID: <1dd2a5cb7d5febcdd791f65c4ccea76219458e59-EmailReplacePatchSet-HTML@...2715...> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Disposition: inline Content-Type: multipart/alternative; boundary="NUTPtKFCz+0="; charset=UTF-8 Subject: [Openvpn-devel] [XS] Change in openvpn[master]: dco: add standard mi prefix handling to multi_process_incoming_dco() List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: plaisthos , flichtenheld Cc: openvpn-devel --NUTPtKFCz+0= Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Attention is currently required from: cron2, flichtenheld, ordex, plaisthos. cron2 has uploaded a new patch set (#3) to the change originally created by= ordex. ( http://gerrit.openvpn.net/c/openvpn/+/1116?usp=3Demail ) The following approvals got outdated and were removed: Code-Review-1 by cron2 Change subject: dco: add standard mi prefix handling to multi_process_incom= ing_dco() ...................................................................... dco: add standard mi prefix handling to multi_process_incoming_dco() Our code generally expects functions that deal with a multi instance to set up a log prefix at the beginning with set_prefix(mi) and clear it at the end with clear_prefix(). Add the calls to multi_process_incoming_dco() in a similar way to what is done for multi_process_incoming_link() - handling "link events" and "dco events" the same, with correct prefix in the function and no leftover prefix afterwards. Github: closes OpenVPN/openvpn#799 Change-Id: I1ad5df0f6785ffe9becd9f83329a9335d1a36f24 Signed-off-by: Antonio Quartulli Signed-off-by: Gert Doering --- M src/openvpn/multi.c 1 file changed, 2 insertions(+), 0 deletions(-) git pull ssh://gerrit.openvpn.net:29418/openvpn refs/changes/16/1116/3 diff --git a/src/openvpn/multi.c b/src/openvpn/multi.c index 85975ff..40c7f8f 100644 --- a/src/openvpn/multi.c +++ b/src/openvpn/multi.c @@ -3294,6 +3294,7 @@ if ((peer_id < m->max_clients) && (m->instances[peer_id])) { mi =3D m->instances[peer_id]; + set_prefix(mi); if (dco->dco_message_type =3D=3D OVPN_CMD_DEL_PEER) { process_incoming_del_peer(m, mi, dco); @@ -3311,6 +3312,7 @@ { tls_session_soft_reset(mi->context.c2.tls_multi); } + clear_prefix(); } else { -- To view, visit http://gerrit.openvpn.net/c/openvpn/+/1116?usp=3Demail To unsubscribe, or for help writing mail filters, visit http://gerrit.openv= pn.net/settings Gerrit-Project: openvpn Gerrit-Branch: master Gerrit-Change-Id: I1ad5df0f6785ffe9becd9f83329a9335d1a36f24 Gerrit-Change-Number: 1116 Gerrit-PatchSet: 3 Gerrit-Owner: ordex Gerrit-Reviewer: cron2 Gerrit-Reviewer: flichtenheld Gerrit-Reviewer: plaisthos Gerrit-CC: openvpn-devel Gerrit-Attention: plaisthos Gerrit-Attention: cron2 Gerrit-Attention: flichtenheld Gerrit-Attention: ordex Gerrit-MessageType: newpatchset --NUTPtKFCz+0= Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable

Attention is currently required from: cron2, flichtenheld, ordex, plais= thos.

cron2 uploaded patch set #3 to the change originally cr= eated by ordex.

View Change

The following approvals got outdated an= d were removed: Code-Review-1 by cron2

dco: add standard mi prefix handling to multi_proces=
s_incoming_dco()

Our code generally expects functions that deal with= a multi instance
to set up a log prefix at the beginning with set_prefi= x(mi) and clear
it at the end with clear_prefix().

Add the calls = to multi_process_incoming_dco() in a similar way to
what is done for mul= ti_process_incoming_link() - handling "link
events" and "= dco events" the same, with correct prefix in the
function and no le= ftover prefix afterwards.

Github: closes OpenVPN/openvpn#799
Chan= ge-Id: I1ad5df0f6785ffe9becd9f83329a9335d1a36f24
Signed-off-by: Antonio = Quartulli <antonio@...2726...>
Signed-off-by: Gert Doering <ger= t@...1296...>
---
M src/openvpn/multi.c
1 file changed, 2 inser= tions(+), 0 deletions(-)

git pull ssh://gerrit.openvpn.net:29418/=
openvpn refs/changes/16/1116/3
diff --git a/src/openvpn/multi.c b/s=
rc/openvpn/multi.c
index 85975ff..40c7f8f 100644
= --- a/src/openvpn/multi.c
+++ b/src/openvpn/multi.c
@@ -3294,6 +3294,7 @@
if ((peer_id <= m->max_clients) && (m->instances[peer_id]))
= {
mi =3D m->instances[peer_id];
= + set_prefix(mi);=
if (dco->dco_message_type =3D=3D OVPN_CMD_DEL_PEER)
{
process_incoming_del= _peer(m, mi, dco);
@@ -3311,6 +3312,7 @@
= {
tls_session_soft_reset(mi->context= .c2.tls_multi);
}
+ clear_prefix();
}
else
{

To view, visit change 1116. To unsubscribe, or for help writing mail filte= rs, visit settings.

<= div itemscope itemtype=3D"http://schema.org/EmailMessage">
<= meta itemprop=3D"name" content=3D"View Change"/>
Gerrit-Project: openvpn
Gerrit-Branch: master
Gerrit-Change-Id: I1ad5df0f6785ffe9becd9f83329= a9335d1a36f24
Gerrit-Change-Number: 1116
Gerrit-PatchSet: 3
Gerrit-Owner: ordex <antonio@...2726...>=
Gerrit-Reviewer: cron2 <gert@...1296...>=
Gerrit-Reviewer: flichtenheld <frank@...2716...= 1...>
Gerrit-Reviewer: plaisthos <arne-openvpn@...1186...= .1227...>
Gerrit-CC: openvpn-devel <openvpn-devel@...1484...= ts.sourceforge.net>
Gerrit-Attention: plaisthos <arne-openvpn@...220...= ..1227...>
Gerrit-Attention: cron2 <gert@...1296...>= ;
Gerrit-Attention: flichtenheld <frank@...2375...= 41...>
Gerrit-Attention: ordex <antonio@...2726...= >
Gerrit-MessageType: newpatchset
--NUTPtKFCz+0=--