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

Commit 3a25e819 authored by Treehugger Robot's avatar Treehugger Robot Committed by Gerrit Code Review
Browse files

Merge "fix commends in last change" into main

parents 862b9951 2c790f7b
Loading
Loading
Loading
Loading
+4 −0
Original line number Diff line number Diff line
@@ -47,6 +47,10 @@ public class ByteBufferReader {

    public String readString() {
        int length = readInt();
        if (length > 1024) {
            throw new AconfigStorageException(
                    "String length exceeds maximum allowed size (1024 bytes): " + length);
        }
        byte[] bytes = new byte[length];
        mByteBuffer.get(bytes, 0, length);
        return new String(bytes, StandardCharsets.UTF_8);
+5 −5
Original line number Diff line number Diff line
@@ -39,12 +39,12 @@ public class AconfigPackageImpl {

    /** @hide */
    public static AconfigPackageImpl load(
            String packageGroupName, String packageName, StorageFileProvider fileProvider) {
        if (packageGroupName == null) {
            String container, String packageName, StorageFileProvider fileProvider) {
        if (container == null) {
            return null;
        }
        AconfigPackageImpl aPackage = new AconfigPackageImpl();
        if (!aPackage.init(packageGroupName, packageName, fileProvider)) {
        if (!aPackage.init(container, packageName, fileProvider)) {
            return null;
        }
        return aPackage;
@@ -75,9 +75,9 @@ public class AconfigPackageImpl {
    }

    private boolean init(
            String packageGroupName, String packageName, StorageFileProvider fileProvider) {
            String containerName, String packageName, StorageFileProvider fileProvider) {
        StrictMode.ThreadPolicy oldPolicy = StrictMode.allowThreadDiskReads();
        String container = packageGroupName;
        String container = containerName;
        try {
            // for devices don't have new storage directly return
            if (!fileProvider.containerFileExists(null)) {