[PATCH applied] Re: socket: Never use negative buf->len in link_socket_read*

Gert Doering <[email protected]> Mon, 27 Jul 2026 14:21:24 +0200 (CEST)
Newsgroups gmane.network.openvpn.devel
Message-ID <[email protected]>
This is, if I remember correctly, "integer warning fixes fallout", but
generally a good idea - so buf->len is now either "0" for "no packet" or
">0" for "do something", and errors are communicated via explicit other
channels.

I did stare at this for quite a while, but since the code is complex I'm
happy that Arne also did and +2ed in gerrit.  Tested on the t_client/
t_server framework.

Your patch has been applied to the master branch.

commit 74c2a965d39fea89c2fe392663eb699fb1324611
Author: Frank Lichtenheld
Date:   Wed Jul 8 17:28:47 2026 +0200

     socket: Never use negative buf->len in link_socket_read*

     Signed-off-by: Frank Lichtenheld <[email protected]>
     Acked-by: Arne Schwabe <[email protected]>
     Gerrit URL: https://gerrit.openvpn.net/c/openvpn/+/1554
     Message-Id: <[email protected]>
     URL: https://www.mail-archive.com/[email protected]/msg37536.html
     Signed-off-by: Gert Doering <[email protected]>


--
kind regards,

Gert Doering