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

Commit 5e04f349 authored by Chalard Jean's avatar Chalard Jean Committed by Automerger Merge Worker
Browse files

Merge changes from topics "api-fix-networkagent", "satisfiedby" am: b7b68cb3

Change-Id: I775f03a40f156df8c5b8a82361687014c866137c
parents 69f2ad71 b7b68cb3
Loading
Loading
Loading
Loading
+3 −2
Original line number Diff line number Diff line
@@ -46,6 +46,7 @@ import com.android.telephony.Rlog;

import java.io.FileDescriptor;
import java.io.PrintWriter;
import java.time.Duration;

/**
 * This class represents a network agent which is communication channel between
@@ -283,7 +284,7 @@ public class DcNetworkAgent extends NetworkAgent {
    }

    @Override
    public synchronized void onStartSocketKeepalive(int slot, int intervalSeconds,
    public synchronized void onStartSocketKeepalive(int slot, @NonNull Duration interval,
            @NonNull KeepalivePacketData packet) {
        if (mDataConnection == null) {
            loge("onStartSocketKeepalive called on no-owner DcNetworkAgent!");
@@ -292,7 +293,7 @@ public class DcNetworkAgent extends NetworkAgent {

        if (packet instanceof NattKeepalivePacketData) {
            mDataConnection.obtainMessage(DataConnection.EVENT_KEEPALIVE_START_REQUEST,
                    slot, intervalSeconds, packet).sendToTarget();
                    slot, (int) interval.getSeconds(), packet).sendToTarget();
        } else {
            sendSocketKeepaliveEvent(slot, SocketKeepalive.ERROR_UNSUPPORTED);
        }