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

Commit 6763aa2c authored by Steve Kondik's avatar Steve Kondik Committed by Gerrit Code Review
Browse files

Merge "ipconfig.txt: fix a possible error in parsing" into ics

parents 42d2cf55 4f33e1f4
Loading
Loading
Loading
Loading
+4 −0
Original line number Diff line number Diff line
@@ -740,6 +740,7 @@ class WifiConfigStore {
            in = new DataInputStream(new BufferedInputStream(new FileInputStream(
                    ipConfigFile)));

            int pos = 0;
            int version = in.readInt();
            if (version != 2 && version != 1) {
                loge("Bad version on IP configuration file, ignore read");
@@ -796,6 +797,8 @@ class WifiConfigStore {
                        } else if (key.equals(EXCLUSION_LIST_KEY)) {
                            exclusionList = in.readUTF();
                        } else if (key.equals(EOS)) {
                            // an eos can be present after the version header
                            if (pos == 0) continue;
                            break;
                        } else {
                            loge("Ignore unknown key " + key + "while reading");
@@ -803,6 +806,7 @@ class WifiConfigStore {
                    } catch (IllegalArgumentException e) {
                        loge("Ignore invalid address while reading" + e);
                    }
                    pos++;
                } while (true);

                if (id != -1) {