aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDmitry Shmidt <dimitrysh@google.com>2011-06-14 20:57:04 -0700
committerAndroid Git Automerger <android-git-automerger@android.com>2011-06-14 20:57:04 -0700
commit153e43407d580b178f4b084ad78417179138b11a (patch)
tree09d6d6bbbebe9200fafe6ac05e0bf496efed8a00
parent62e2ee120e41a91a2547311d33cb4681132cdaa2 (diff)
parentd870426cf67e614e4cb938f9e66e00eeb57febc4 (diff)
downloadexternal_dhcpcd-153e43407d580b178f4b084ad78417179138b11a.zip
external_dhcpcd-153e43407d580b178f4b084ad78417179138b11a.tar.gz
external_dhcpcd-153e43407d580b178f4b084ad78417179138b11a.tar.bz2
am d870426c: am 49b71a9e: Check dst addr for NULL incase of IFF_POINTOPOINT interface (b/4603819)
* commit 'd870426cf67e614e4cb938f9e66e00eeb57febc4': Check dst addr for NULL incase of IFF_POINTOPOINT interface (b/4603819)
-rw-r--r--net.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/net.c b/net.c
index e26b8d4..f3147d6 100644
--- a/net.c
+++ b/net.c
@@ -526,7 +526,8 @@ do_address(const char *ifname,
addr->s_addr = a->sin_addr.s_addr;
net->s_addr = n->sin_addr.s_addr;
if (dst) {
- if (ifa->ifa_flags & IFF_POINTOPOINT)
+ /* TODO: Fix getifaddrs() */
+ if ((ifa->ifa_flags & IFF_POINTOPOINT) && d)
dst->s_addr = d->sin_addr.s_addr;
else
dst->s_addr = INADDR_ANY;