diff options
| author | Neil Fuller <nfuller@google.com> | 2019-06-20 14:06:50 -0700 |
|---|---|---|
| committer | android-build-merger <android-build-merger@google.com> | 2019-06-20 14:06:50 -0700 |
| commit | 9ec43cc7fe1f3aea02ed2a97ce6a38617cce86ec (patch) | |
| tree | c8b6802f649912b8f22052769cca47d936244710 /core/java/android | |
| parent | 15199a586861dde13d36f955900d254abd0f63c4 (diff) | |
| parent | a357696c2f609d621ce347feb8c8ea852ea23b98 (diff) | |
Merge "Switch to a single PacketSocketAddress constructor" am: 2d24f7a39e
am: a357696c2f
Change-Id: I7db11188d9dd42e25b0aebd79acc92a9ba2f56a0
Diffstat (limited to 'core/java/android')
| -rw-r--r-- | core/java/android/net/util/SocketUtils.java | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/core/java/android/net/util/SocketUtils.java b/core/java/android/net/util/SocketUtils.java index 1364d8c17e1b..d9bcb3ce0d8f 100644 --- a/core/java/android/net/util/SocketUtils.java +++ b/core/java/android/net/util/SocketUtils.java @@ -69,7 +69,10 @@ public final class SocketUtils { */ @NonNull public static SocketAddress makePacketSocketAddress(int protocol, int ifIndex) { - return new PacketSocketAddress((short) protocol, ifIndex); + return new PacketSocketAddress( + (short) protocol /* sll_protocol */, + ifIndex /* sll_ifindex */, + null /* sll_addr */); } /** @@ -77,7 +80,10 @@ public final class SocketUtils { */ @NonNull public static SocketAddress makePacketSocketAddress(int ifIndex, @NonNull byte[] hwAddr) { - return new PacketSocketAddress(ifIndex, hwAddr); + return new PacketSocketAddress( + (short) 0 /* sll_protocol */, + ifIndex /* sll_ifindex */, + hwAddr /* sll_addr */); } /** |
