OSDN Git Service

DO NOT MERGE: backport the IPv6 NetworkInterface/multicast fixes.
authorElliott Hughes <enh@google.com>
Thu, 26 Nov 2009 20:44:42 +0000 (12:44 -0800)
committerElliott Hughes <enh@google.com>
Thu, 26 Nov 2009 21:01:18 +0000 (13:01 -0800)
commit5d26339aed33942ba82bfdb79e1b7e9a832c96a7
tree5f9731707cc1fbd3cb742dc13836d61530bb6693
parent1c7705b6066ea57109557fc1cb0609991ac0af24
DO NOT MERGE: backport the IPv6 NetworkInterface/multicast fixes.

This is a backport of the minimal changes from master (flan) to fix IPv6
multicasting. Specifically, it fixes NetworkInterface to report IPv6 addresses,
it fixes GenericIPMreq so we pass the interface indexes down to native code,
it replaces our old copy of harmony's MulticastSocketTest with the current
upstream version (to avoid bogus failures), and it brings back one small
"unrelated" fix to OSNetworkSystem.cpp that's necessary to prevent failures
in later parts of tests we used to fail too early to notice secondary
problems.

This passes all the (fixed) MulticastSocketTest tests, causes no regressions
in the whole net.AllTests suite, and fixes the user-submitted application
that started the investigation.

Bug: 1750581
12 files changed:
libcore/Android.mk
libcore/include/LocalArray.h [new file with mode: 0644]
libcore/include/ScopedFd.h [new file with mode: 0644]
libcore/luni/src/main/java/java/net/InterfaceAddress.java [new file with mode: 0644]
libcore/luni/src/main/java/java/net/NetworkInterface.java
libcore/luni/src/main/java/org/apache/harmony/luni/net/GenericIPMreq.java
libcore/luni/src/main/native/ifaddrs-android.h [new file with mode: 0644]
libcore/luni/src/main/native/java_net_NetworkInterface.c [deleted file]
libcore/luni/src/main/native/java_net_NetworkInterface.cpp [new file with mode: 0644]
libcore/luni/src/main/native/org_apache_harmony_luni_platform_OSNetworkSystem.cpp
libcore/luni/src/main/native/sub.mk
libcore/luni/src/test/java/tests/api/java/net/MulticastSocketTest.java