On Linux those functions actually take void pointer, so no behavior change there. On Windows, we avoid warnings about unsigned char vs char.
Signed-off-by: Frank Lichtenheld <fr...@lichtenheld.com> --- src/openvpn/manage.c | 4 ++-- src/openvpn/proxy.c | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/openvpn/manage.c b/src/openvpn/manage.c index 8397d3cf..3ea1992b 100644 --- a/src/openvpn/manage.c +++ b/src/openvpn/manage.c @@ -2251,7 +2251,7 @@ man_read(struct management *man) man->connection.lastfdreceived = fd; } #else /* ifdef TARGET_ANDROID */ - len = recv(man->connection.sd_cli, buf, sizeof(buf), MSG_NOSIGNAL); + len = recv(man->connection.sd_cli, (void *)buf, sizeof(buf), MSG_NOSIGNAL); #endif if (len == 0) @@ -2348,7 +2348,7 @@ man_write(struct management *man) } else #endif - sent = send(man->connection.sd_cli, BPTR(buf), len, MSG_NOSIGNAL); + sent = send(man->connection.sd_cli, (const void *)BPTR(buf), len, MSG_NOSIGNAL); if (sent >= 0) { buffer_list_advance(man->connection.out, sent); diff --git a/src/openvpn/proxy.c b/src/openvpn/proxy.c index aa10363c..ed47eaa2 100644 --- a/src/openvpn/proxy.c +++ b/src/openvpn/proxy.c @@ -126,7 +126,7 @@ recv_line(socket_descriptor_t sd, } /* read single char */ - size = recv(sd, &c, 1, MSG_NOSIGNAL); + size = recv(sd, (void *)&c, 1, MSG_NOSIGNAL); /* error? */ if (size != 1) -- 2.34.1 _______________________________________________ Openvpn-devel mailing list Openvpn-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/openvpn-devel