Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- diff -u ipcp.c.orig ipcp.c
- --- ipcp.c.orig 2005-01-27 12:09:33.000000000 -0200
- +++ ipcp.c 2008-12-02 19:12:49.000000000 -0200
- @@ -690,7 +690,7 @@
- if (bundle->ncp.cfg.sendpipe > 0 || bundle->ncp.cfg.recvpipe > 0) {
- ncprange_getsa(&myrange, &ssgw, &ssmask);
- ncpaddr_getsa(&hisncpaddr, &ssdst);
- - rt_Update(bundle, sadst, sagw, samask);
- + rt_Update(bundle, sadst, sagw, samask, NULL, NULL);
- }
- if (Enabled(bundle, OPT_SROUTES))
- diff -ur ipv6cp.c.orig ipv6cp.c
- --- ipv6cp.c.orig 2005-01-27 12:09:33.000000000 -0200
- +++ ipv6cp.c 2008-12-02 19:12:58.000000000 -0200
- @@ -245,7 +245,7 @@
- ncpaddr_getsa(&ipv6cp->hisaddr, &ssdst);
- else
- sadst = NULL;
- - rt_Update(bundle, sadst, sagw, samask);
- + rt_Update(bundle, sadst, sagw, samask, NULL, NULL);
- }
- if (Enabled(bundle, OPT_SROUTES))
- diff -ur route.c.orig route.c
- --- route.c.orig 2005-01-10 09:12:36.000000000 -0200
- +++ route.c 2008-12-03 10:09:09.000000000 -0200
- @@ -524,7 +524,8 @@
- " mtu %lu\n", rtm->rtm_index, Index2Nam(rtm->rtm_index),
- ncprange_ntoa(&dst), bundle->iface->mtu);
- }
- - rt_Update(bundle, sa[RTAX_DST], sa[RTAX_GATEWAY], sa[RTAX_NETMASK]);
- + rt_Update(bundle, sa[RTAX_DST], sa[RTAX_GATEWAY], sa[RTAX_NETMASK],
- + sa[RTAX_IFP], sa[RTAX_IFA]);
- }
- }
- @@ -862,7 +863,8 @@
- void
- rt_Update(struct bundle *bundle, const struct sockaddr *dst,
- - const struct sockaddr *gw, const struct sockaddr *mask)
- + const struct sockaddr *gw, const struct sockaddr *mask,
- + const struct sockaddr *ifp, const struct sockaddr *ifa)
- {
- struct ncprange ncpdst;
- struct rtmsg rtmes;
- @@ -909,6 +911,13 @@
- p += memcpy_roundup(p, mask, mask->sa_len);
- }
- + if (ifp && ifp->sa_family == AF_LINK && ifa) {
- + rtmes.m_rtm.rtm_addrs |= RTA_IFP;
- + p += memcpy_roundup(p, ifp, ifp->sa_len);
- + rtmes.m_rtm.rtm_addrs |= RTA_IFA;
- + p += memcpy_roundup(p, ifa, ifa->sa_len);
- + }
- +
- rtmes.m_rtm.rtm_msglen = p - (char *)&rtmes;
- wb = ID0write(s, &rtmes, rtmes.m_rtm.rtm_msglen);
- diff -ur route.h.orig route.h
- --- route.h.orig 2001-08-15 23:01:05.000000000 -0300
- +++ route.h 2008-12-03 10:07:30.000000000 -0200
- @@ -70,4 +70,5 @@
- extern int rt_Set(struct bundle *, int, const struct ncprange *,
- const struct ncpaddr *, int, int);
- extern void rt_Update(struct bundle *, const struct sockaddr *,
- + const struct sockaddr *, const struct sockaddr *,
- const struct sockaddr *, const struct sockaddr *);
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement