summaryrefslogtreecommitdiffstats
path: root/ipv6rs.c
diff options
context:
space:
mode:
authorRoy Marples <roy@marples.name>2013-01-18 19:59:01 +0000
committerRoy Marples <roy@marples.name>2013-01-18 19:59:01 +0000
commitfe292175a1d0dc06a0c8a528482b091766e6d134 (patch)
tree63b13ba2fb85ee20a9dd3bf95589561ceed29658 /ipv6rs.c
parent332a5fe6272ac96d673ef4c8dcbbf52e36db84ec (diff)
downloaddhcpcd-fe292175a1d0dc06a0c8a528482b091766e6d134.tar.xz
Check the correct interface the RAP came from before overwriting it.
Diffstat (limited to 'ipv6rs.c')
-rw-r--r--ipv6rs.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/ipv6rs.c b/ipv6rs.c
index 58813472..3b18750a 100644
--- a/ipv6rs.c
+++ b/ipv6rs.c
@@ -469,7 +469,8 @@ ipv6rs_handledata(_unused void *arg)
return;
}
TAILQ_FOREACH(rap, &ipv6_routers, next) {
- if (memcmp(rap->from.s6_addr, from.sin6_addr.s6_addr,
+ if (ifp == rap->iface &&
+ memcmp(rap->from.s6_addr, from.sin6_addr.s6_addr,
sizeof(rap->from.s6_addr)) == 0)
break;
}