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

Commit 72e1cea0 authored by Roshan Pius's avatar Roshan Pius
Browse files

WifiSsid: Catch String out of bound exception

Bug: 130843215
Test: None
Change-Id: I6046bf0fe9e9c402e565e5fa63f0e0aec711725c
parent 3979c51c
Loading
Loading
Loading
Loading
+2 −0
Original line number Diff line number Diff line
@@ -129,6 +129,8 @@ public class WifiSsid implements Parcelable {
                                val = Integer.parseInt(asciiEncoded.substring(i, i + 2), HEX_RADIX);
                            } catch (NumberFormatException e) {
                                val = -1;
                            } catch (StringIndexOutOfBoundsException e) {
                                val = -1;
                            }
                            if (val < 0) {
                                val = Character.digit(asciiEncoded.charAt(i), HEX_RADIX);