Hi Tom, first of all, thanks a lot for your contribution!
On 03/11/2019 06:30, Tom Yan wrote: > --- > src/openvpn/networking_iproute2.c | 6 ++++-- > 1 file changed, 4 insertions(+), 2 deletions(-) > > diff --git a/src/openvpn/networking_iproute2.c > b/src/openvpn/networking_iproute2.c > index 1ddeb5cf..4e2435c1 100644 > --- a/src/openvpn/networking_iproute2.c > +++ b/src/openvpn/networking_iproute2.c > @@ -98,8 +98,10 @@ net_addr_v4_add(openvpn_net_ctx_t *ctx, const char *iface, > const char *addr_str = print_in_addr_t(*addr, 0, &ctx->gc); > const char *brd_str = print_in_addr_t(*broadcast, 0, &ctx->gc); > > - argv_printf(&argv, "%s addr add dev %s %s/%d broadcast %s", iproute_path, > - iface, addr_str, prefixlen, brd_str); > + argv_printf(&argv, "%s addr add dev %s %s/%d", iproute_path, > + iface, addr_str, prefixlen); > + if (prefixlen < 31) > + argv_printf_cat(&argv, " broadcast %s", brd_str); Unfortunately I am not able to grasp this fix entirely.. (maybe because I don't know RFC3021). Would you mind explaining *why* this is needed? What is this change fixing? Can you make an example where the actual code fails and how this change is fixing it? It would also be very nice if you could add such information to the commit message, so that it will remain in the git history. Thanks a lot! Regards, > argv_msg(M_INFO, &argv); > openvpn_execve_check(&argv, ctx->es, S_FATAL, "Linux ip addr add > failed"); > > -- Antonio Quartulli _______________________________________________ Openvpn-devel mailing list Openvpn-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/openvpn-devel