[M] Change in openvpn[master]: Add helper method to read an integer from a buffer

"cron2 \(Code Review\) via Openvpn-devel" <[email protected]>
Newsgroups gmane.network.openvpn.devel
Message-ID <b0c018437329c2dc95de7fcd83e6bdcd13b4683d-EmailReviewComments-HTML@gerrit.openvpn.net>
Attention is currently required from: plaisthos, razvanc.

cron2 has posted comments on this change by plaisthos. ( http://gerrit.openvpn.net/c/openvpn/+/1855?usp=email )

Change subject: Add helper method to read an integer from a buffer
......................................................................


Patch Set 5:

(2 comments)

Patchset:

PS5: 
> I am not sure we need `buffer_read_int()` at all, for two reasons: […]
`buf_read_u64()` reads a binary-encoded 8 byte integer, not a decimal-encoded one


File src/openvpn/buffer.c:

http://gerrit.openvpn.net/c/openvpn/+/1855/comment/b313daa5_c502a9de?usp=email :
PS5, Line 1400:         if (c >= '0' && c <= '9')
> We have `char_class(c, CC_DIGIT)`, would that fit this purpose?
for explicit integer parsing, the code "as written" with explicit `c >= '0'...` is much easier to understand



-- 
To view, visit http://gerrit.openvpn.net/c/openvpn/+/1855?usp=email
To unsubscribe, or for help writing mail filters, visit http://gerrit.openvpn.net/settings?usp=email

Gerrit-MessageType: comment
Gerrit-Project: openvpn
Gerrit-Branch: master
Gerrit-Change-Id: Ifdd2122a3e60cdb11cc9df67570ab5628bfcdeea
Gerrit-Change-Number: 1855
Gerrit-PatchSet: 5
Gerrit-Owner: plaisthos <[email protected]>
Gerrit-CC: cron2 <[email protected]>
Gerrit-CC: openvpn-devel <[email protected]>
Gerrit-CC: razvanc <[email protected]>
Gerrit-Attention: plaisthos <[email protected]>
Gerrit-Attention: razvanc <[email protected]>
Gerrit-Comment-Date: Wed, 26 Aug 2026 06:16:39 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: razvanc <[email protected]>

_______________________________________________
Openvpn-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/openvpn-devel
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.