Merge "Remove NetdService usage from EthernetTracker." am: 479ee83516
Original change: https://android-review.googlesource.com/c/platform/frameworks/opt/net/ethernet/+/1925901 Change-Id: I831bec7800020c589b7651cc77c9c6f0e48734c0
This commit is contained in:
@@ -40,7 +40,6 @@ import android.os.ServiceManager;
|
|||||||
import android.text.TextUtils;
|
import android.text.TextUtils;
|
||||||
import android.util.ArrayMap;
|
import android.util.ArrayMap;
|
||||||
import android.util.Log;
|
import android.util.Log;
|
||||||
import android.net.util.NetdService;
|
|
||||||
|
|
||||||
import com.android.internal.annotations.VisibleForTesting;
|
import com.android.internal.annotations.VisibleForTesting;
|
||||||
import com.android.internal.util.IndentingPrintWriter;
|
import com.android.internal.util.IndentingPrintWriter;
|
||||||
@@ -124,7 +123,9 @@ final class EthernetTracker {
|
|||||||
// The services we use.
|
// The services we use.
|
||||||
IBinder b = ServiceManager.getService(Context.NETWORKMANAGEMENT_SERVICE);
|
IBinder b = ServiceManager.getService(Context.NETWORKMANAGEMENT_SERVICE);
|
||||||
mNMService = INetworkManagementService.Stub.asInterface(b);
|
mNMService = INetworkManagementService.Stub.asInterface(b);
|
||||||
mNetd = Objects.requireNonNull(NetdService.getInstance(), "could not get netd instance");
|
mNetd = INetd.Stub.asInterface(
|
||||||
|
(IBinder) context.getSystemService(Context.NETD_SERVICE));
|
||||||
|
Objects.requireNonNull(mNetd, "could not get netd instance");
|
||||||
|
|
||||||
// Interface match regex.
|
// Interface match regex.
|
||||||
updateIfaceMatchRegexp();
|
updateIfaceMatchRegexp();
|
||||||
|
|||||||
Reference in New Issue
Block a user