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

Commit 9eb21416 authored by Benedict Wong's avatar Benedict Wong
Browse files

Update the constants to use Environment

This change updates the file storage constants to use the Environment
system data paths instead of redefined constants.

Bug: 215406468
Test: atest FrameworksVcnTests
Change-Id: If11c600601704b78527c3c1b48cc908e75f3d791
parent 1428215b
Loading
Loading
Loading
Loading
+4 −1
Original line number Diff line number Diff line
@@ -52,6 +52,7 @@ import android.net.vcn.VcnManager.VcnStatusCode;
import android.net.vcn.VcnUnderlyingNetworkPolicy;
import android.net.wifi.WifiInfo;
import android.os.Binder;
import android.os.Environment;
import android.os.Handler;
import android.os.HandlerThread;
import android.os.IBinder;
@@ -82,6 +83,7 @@ import com.android.server.vcn.VcnContext;
import com.android.server.vcn.VcnNetworkProvider;
import com.android.server.vcn.util.PersistableBundleUtils;

import java.io.File;
import java.io.FileDescriptor;
import java.io.IOException;
import java.io.PrintWriter;
@@ -162,7 +164,8 @@ public class VcnManagementService extends IVcnManagementService.Stub {
    public static final boolean VDBG = false; // STOPSHIP: if true

    @VisibleForTesting(visibility = Visibility.PRIVATE)
    static final String VCN_CONFIG_FILE = "/data/system/vcn/configs.xml";
    static final String VCN_CONFIG_FILE =
            new File(Environment.getDataSystemDirectory(), "vcn/configs.xml").getPath();

    /* Binder context for this service */
    @NonNull private final Context mContext;