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 <antonio@mandelbit.com>
Signed-off-by: Gert Doering <gert@greenie.muc.de>
Acked-by: Gert Doering <gert@greenie.muc.de>
Message-Id: <20250911201222.25382-1-gert@greenie.muc.de>
URL: https://www.mail-archive.com/openvpn-devel@lists.sourceforge.net/msg32859.html
URL: https://gerrit.openvpn.net/c/openvpn/+/1116
Signed-off-by: Gert Doering <gert@greenie.muc.de>
(cherry picked from commit 531fef40b73f73632548c88697af34cf15a70531)
| ... | ... |
@@ -3309,6 +3309,7 @@ multi_process_incoming_dco(struct multi_context *m) |
| 3309 | 3309 |
if ((peer_id < m->max_clients) && (m->instances[peer_id])) |
| 3310 | 3310 |
{
|
| 3311 | 3311 |
mi = m->instances[peer_id]; |
| 3312 |
+ set_prefix(mi); |
|
| 3312 | 3313 |
if (dco->dco_message_type == OVPN_CMD_DEL_PEER) |
| 3313 | 3314 |
{
|
| 3314 | 3315 |
process_incoming_del_peer(m, mi, dco); |
| ... | ... |
@@ -3328,6 +3329,7 @@ multi_process_incoming_dco(struct multi_context *m) |
| 3328 | 3328 |
{
|
| 3329 | 3329 |
tls_session_soft_reset(mi->context.c2.tls_multi); |
| 3330 | 3330 |
} |
| 3331 |
+ clear_prefix(); |
|
| 3331 | 3332 |
} |
| 3332 | 3333 |
else |
| 3333 | 3334 |
{
|