OK. Here it is - PtP patch from Andrew J. Schorr. No problems with ospfd,
ripd might need some more testing though.
diff --git a/bgpd/bgp_nexthop.c b/bgpd/bgp_nexthop.c
index 4100e3d..c50eeed 100644
--- a/bgpd/bgp_nexthop.c
+++ b/bgpd/bgp_nexthop.c
@@ -666,7 +666,7 @@
p.family = AF_INET;
p.prefixlen = addr->prefixlen;
- if (if_is_pointopoint (ifp))
+ if (CONNECTED_POINTOPOINT_HOST(ifc))
p.u.prefix4 = dest->u.prefix4;
else
p.u.prefix4 = addr->u.prefix4;
@@ -697,7 +697,7 @@
p.family = AF_INET6;
p.prefixlen = addr->prefixlen;
- if (if_is_pointopoint (ifp))
+ if (if_is_pointopoint (ifp) && dest)
p.u.prefix6 = dest->u.prefix6;
else
p.u.prefix6 = addr->u.prefix6;
@@ -751,7 +751,7 @@
p.family = AF_INET;
p.prefixlen = addr->prefixlen;
- if (if_is_pointopoint (ifp))
+ if (CONNECTED_POINTOPOINT_HOST(ifc))
p.u.prefix4 = dest->u.prefix4;
else
p.u.prefix4 = addr->u.prefix4;
@@ -782,7 +782,7 @@
p.family = AF_INET6;
p.prefixlen = addr->prefixlen;
- if (if_is_pointopoint (ifp))
+ if (if_is_pointopoint (ifp) && dest)
p.u.prefix6 = dest->u.prefix6;
else
p.u.prefix6 = addr->u.prefix6;