From: Roy Marples Date: Tue, 15 Sep 2015 13:37:25 +0000 (+0000) Subject: Some BSD's require the pid explicitly set on route messages. X-Git-Tag: v6.9.4~42 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=aa1c781009353791fcd73daa1b2d24f5744b0e0c;p=thirdparty%2Fdhcpcd.git Some BSD's require the pid explicitly set on route messages. --- diff --git a/if-bsd.c b/if-bsd.c index 772f60d8..06919504 100644 --- a/if-bsd.c +++ b/if-bsd.c @@ -541,6 +541,7 @@ if_route(unsigned char cmd, const struct rt *rt) rtm.hdr.rtm_type = cmd; rtm.hdr.rtm_addrs = RTA_DST; rtm.hdr.rtm_flags = RTF_UP; + rtm.hdr.rtm_pid = getpid(); #ifdef RTF_PINNED if (cmd != RTM_ADD) rtm.hdr.rtm_flags |= RTF_PINNED; @@ -920,6 +921,7 @@ if_route6(unsigned char cmd, const struct rt6 *rt) rtm.hdr.rtm_seq = 1; rtm.hdr.rtm_type = cmd; rtm.hdr.rtm_flags = RTF_UP | (int)rt->flags; + rtm.hdr.rtm_pid = getpid(); #ifdef RTF_PINNED if (rtm.hdr.rtm_type != RTM_ADD) rtm.hdr.rtm_flags |= RTF_PINNED;