Arne Schwabe has uploaded this change for review. ( 
https://gerrit.openvpn.net/c/openvpn/+/2108?usp=email )


Change subject: Silence remaining cppcheck warnings on macOS and FreeBSD
......................................................................

Silence remaining cppcheck warnings on macOS and FreeBSD

Change-Id: I571e30bb22ec7bffc2c5fa04fdcd73b52ce47e5e
Signed-off-by: Arne Schwabe <[email protected]>
---
M src/openvpn/route.c
M src/openvpn/tun.c
2 files changed, 5 insertions(+), 5 deletions(-)



  git pull ssh://gerrit.openvpn.net:29418/openvpn refs/changes/08/2108/1

diff --git a/src/openvpn/route.c b/src/openvpn/route.c
index e8de2d5..99f30d1 100644
--- a/src/openvpn/route.c
+++ b/src/openvpn/route.c
@@ -3333,7 +3333,7 @@
     int rtm_addrs;
     struct sockaddr so_dst, so_mask;
     char *cp = m_rtmsg.m_space;
-    struct sockaddr *gate = NULL, *ifp = NULL, *sa;
+    const struct sockaddr *gate = NULL, *ifp = NULL, *sa;
     struct rt_msghdr *rtm_aux;

 #define rtm m_rtmsg.m_rtm
diff --git a/src/openvpn/tun.c b/src/openvpn/tun.c
index 58f4750..769b4c7 100644
--- a/src/openvpn/tun.c
+++ b/src/openvpn/tun.c
@@ -1042,7 +1042,7 @@
  * @param ctx       the networking API opaque context
  */
 static void
-do_ifconfig_ipv6(struct tuntap *tt, const char *ifname, int tun_mtu, const 
struct env_set *es,
+do_ifconfig_ipv6(const struct tuntap *tt, const char *ifname, int tun_mtu, 
const struct env_set *es,
                  openvpn_net_ctx_t *ctx)
 {
 #if !defined(TARGET_LINUX)
@@ -1233,7 +1233,7 @@
  * @param ctx       the networking API opaque context
  */
 static void
-do_ifconfig_ipv4(struct tuntap *tt, const char *ifname, int tun_mtu, const 
struct env_set *es,
+do_ifconfig_ipv4(const struct tuntap *tt, const char *ifname, int tun_mtu, 
const struct env_set *es,
                  openvpn_net_ctx_t *ctx)
 {
 #if !defined(_WIN32) && !defined(TARGET_ANDROID)
@@ -1589,7 +1589,7 @@
 }

 static void
-undo_ifconfig_ipv4(const struct tuntap *tt, openvpn_net_ctx_t *ctx)
+undo_ifconfig_ipv4(const struct tuntap *tt, const openvpn_net_ctx_t *ctx)
 {
 #if defined(TARGET_LINUX)
     int netbits = netmask_to_netbits2(tt->remote_netmask);
@@ -1624,7 +1624,7 @@
 }

 static void
-undo_ifconfig_ipv6(const struct tuntap *tt, openvpn_net_ctx_t *ctx)
+undo_ifconfig_ipv6(const struct tuntap *tt, const openvpn_net_ctx_t *ctx)
 {
 #if defined(TARGET_LINUX)
     if (net_addr_v6_del(ctx, tt->actual_name, &tt->local_ipv6, 
tt->netbits_ipv6) < 0)

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

Gerrit-MessageType: newchange
Gerrit-Project: openvpn
Gerrit-Branch: master
Gerrit-Change-Id: I571e30bb22ec7bffc2c5fa04fdcd73b52ce47e5e
Gerrit-Change-Number: 2108
Gerrit-PatchSet: 1
Gerrit-Owner: Arne Schwabe <[email protected]>
Gerrit-CC: openvpn-devel <[email protected]>
_______________________________________________
Openvpn-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/openvpn-devel

Reply via email to