Gert Doering has submitted this change. ( 
https://gerrit.openvpn.net/c/openvpn/+/2123?usp=email )

Change subject: route: remove unused max() and gc from BSD get_default_gateway()
......................................................................

route: remove unused max() and gc from BSD get_default_gateway()

Both lost their last users when 76d11614 ("get_default_gateway()
HWADDR overhaul") replaced the SIOCGIFCONF loop with getifaddrs().

Change-Id: I879cd0fe9b1fabb350e1c4558863480064d45903
Signed-off-by: Razvan Cojocaru <[email protected]>
Acked-by: Gert Doering <[email protected]>
Gerrit URL: https://gerrit.openvpn.net/c/openvpn/+/2123
Message-Id: <[email protected]>
URL: 
https://www.mail-archive.com/[email protected]/msg40674.html
Signed-off-by: Gert Doering <[email protected]>
---
M src/openvpn/route.c
1 file changed, 0 insertions(+), 6 deletions(-)




diff --git a/src/openvpn/route.c b/src/openvpn/route.c
index fa569fa..c812dac 100644
--- a/src/openvpn/route.c
+++ b/src/openvpn/route.c
@@ -3329,12 +3329,9 @@
 #define ADVANCE(x, n) (x += ROUNDUP((n)->sa_len))
 #endif

-#define max(a, b) ((a) > (b) ? (a) : (b))
-
 void
 get_default_gateway(struct route_gateway_info *rgi, in_addr_t dest, 
openvpn_net_ctx_t *ctx)
 {
-    struct gc_arena gc = gc_new();
     struct rtmsg m_rtmsg;
     int sockfd = -1;
     int rtm_addrs;
@@ -3536,7 +3533,6 @@
     {
         close(sockfd);
     }
-    gc_free(&gc);
 }

 /* BSD implementation using routing socket (as does IPv4)
@@ -3705,8 +3701,6 @@
     }
 }

-#undef max
-
 #elif defined(TARGET_HAIKU)

 void

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

Gerrit-MessageType: merged
Gerrit-Project: openvpn
Gerrit-Branch: master
Gerrit-Change-Id: I879cd0fe9b1fabb350e1c4558863480064d45903
Gerrit-Change-Number: 2123
Gerrit-PatchSet: 2
Gerrit-Owner: Răzvan Cojocaru <[email protected]>
Gerrit-Reviewer: Arne Schwabe <[email protected]>
Gerrit-Reviewer: Gert Doering <[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