0
0
mirror of https://github.com/OpenVPN/openvpn3.git synced 2024-09-19 19:52:15 +02:00
openvpn3/test
Charlie Vigue dd115d2e83 Fix RouteBase string formatting bug
When correcting conversion issues in RouteBase a to_string bug was
introduced which caused some characters to be escaped when inserted
to the string, for example a prefix_len of 0 would render as "\0"
rather than inserting '0'. The std::ios::binary flag does not seem
to prevent this for std::ostringstream so I have cast the data member
up to uint16_t which should be safe, and solves the issue.

Added a unit test to demonstrate the issue. Old code output was
"0.0.0.0/\0", now outputs "0.0.0.0/0" as expected.

Signed-off-by: Charlie Vigue <charlie.vigue@openvpn.com>
2024-03-29 03:13:00 +00:00
..
ovpncli Add support for mbed TLS 3.0 2024-02-23 15:32:58 +01:00
ssl Fix cmake for removal of proto.cpp 2023-06-16 08:50:38 -07:00
unittests Fix RouteBase string formatting bug 2024-03-29 03:13:00 +00:00
unused copyright: Update to 2022 2022-09-29 12:00:26 +02:00