Skip to content

Commit

Permalink
sorry, it was a typo
Browse files Browse the repository at this point in the history
  • Loading branch information
cnbatch committed May 8, 2024
1 parent 4b0bf5d commit 65dd617
Showing 1 changed file with 6 additions and 5 deletions.
11 changes: 6 additions & 5 deletions src/openvpn/tun.c
Original file line number Diff line number Diff line change
Expand Up @@ -1182,6 +1182,12 @@ do_ifconfig_ipv6(struct tuntap *tt, const char *ifname, int tun_mtu,
openvpn_execve_check(&argv, es, S_FATAL,
"generic BSD ifconfig inet6 failed");

#if defined(TARGET_OPENBSD) || defined(TARGET_NETBSD) \
|| defined(TARGET_DARWIN)
/* and, hooray, we explicitly need to add a route... */
add_route_connected_v6_net(tt, es);
#endif

#elif defined(TARGET_FREEBSD)
/* read current fib number, codes are from: */
/* https://github.com/freebsd/freebsd-src/blob/f9716eee8ab45ad906d9b5c5233ca20c10226ca7/sbin/route/route.c#L269 */
Expand Down Expand Up @@ -1236,11 +1242,6 @@ do_ifconfig_ipv6(struct tuntap *tt, const char *ifname, int tun_mtu,
"FreeBSD BSD 'ifconfig inet6 -ifdisabled' failed");
#endif

#if defined(TARGET_OPENBSD) || defined(TARGET_NETBSD) \
|| defined(TARGET_DARWIN)
/* and, hooray, we explicitly need to add a route... */
add_route_connected_v6_net(tt, es);
#endif
#elif defined(TARGET_AIX)
argv_printf(&argv, "%s %s inet6 %s/%d mtu %d up", IFCONFIG_PATH, ifname,
ifconfig_ipv6_local, tt->netbits_ipv6, tun_mtu);
Expand Down

0 comments on commit 65dd617

Please sign in to comment.