Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit ac6860bb authored by Neil Fuller's avatar Neil Fuller Committed by android-build-merger
Browse files

Merge "Remove unnecessary casts" am: 6c22b3fd am: 51b4202e am: 2c361dd1

am: 67a5214d

Change-Id: I86817759e2d0058332d95cde9eeccf3b8eaf891f
parents fdbd13f5 67a5214d
Loading
Loading
Loading
Loading
+1 −2
Original line number Diff line number Diff line
@@ -476,8 +476,7 @@ public class ApfFilter {
                installNewProgramLocked();
            }
            socket = Os.socket(AF_PACKET, SOCK_RAW, ETH_P_IPV6);
            SocketAddress addr = makePacketSocketAddress(
                    (short) ETH_P_IPV6, mInterfaceParams.index);
            SocketAddress addr = makePacketSocketAddress(ETH_P_IPV6, mInterfaceParams.index);
            Os.bind(socket, addr);
            NetworkStackUtils.attachRaFilter(socket, mApfCapabilities.apfPacketFormat);
        } catch(SocketException|ErrnoException e) {
+1 −1
Original line number Diff line number Diff line
@@ -371,7 +371,7 @@ public class DhcpClient extends StateMachine {
    private boolean initPacketSocket() {
        try {
            mPacketSock = Os.socket(AF_PACKET, SOCK_RAW, ETH_P_IP);
            SocketAddress addr = makePacketSocketAddress((short) ETH_P_IP, mIface.index);
            SocketAddress addr = makePacketSocketAddress(ETH_P_IP, mIface.index);
            Os.bind(mPacketSock, addr);
            NetworkStackUtils.attachDhcpFilter(mPacketSock);
        } catch(SocketException|ErrnoException e) {
+1 −1
Original line number Diff line number Diff line
@@ -104,7 +104,7 @@ public class ConnectivityPacketTracker {
            try {
                s = Os.socket(AF_PACKET, SOCK_RAW | SOCK_NONBLOCK, 0);
                NetworkStackUtils.attachControlPacketFilter(s, ARPHRD_ETHER);
                Os.bind(s, makePacketSocketAddress((short) ETH_P_ALL, mInterface.index));
                Os.bind(s, makePacketSocketAddress(ETH_P_ALL, mInterface.index));
            } catch (ErrnoException | IOException e) {
                logError("Failed to create packet tracking socket: ", e);
                closeFd(s);