diff options
author | Shareef Ali <shareefalis@cyanogenmod.org> | 2013-07-29 22:14:17 +0000 |
---|---|---|
committer | Gerrit Code Review <gerrit@cyanogenmod.org> | 2013-07-29 22:14:17 +0000 |
commit | 94987a5fa375195f25afe13c24ff1a6f04143bc8 (patch) | |
tree | eaf0242466b88273c4b9c0601d4e1095e194a0c3 | |
parent | ef61f36300a3bca75bd0d06ad7d89e474c208af4 (diff) | |
download | frameworks_opt_telephony-94987a5fa375195f25afe13c24ff1a6f04143bc8.zip frameworks_opt_telephony-94987a5fa375195f25afe13c24ff1a6f04143bc8.tar.gz frameworks_opt_telephony-94987a5fa375195f25afe13c24ff1a6f04143bc8.tar.bz2 |
Revert "SamsungQualcommRIL: always convert hex to int."
This reverts commit ef61f36300a3bca75bd0d06ad7d89e474c208af4.
Change-Id: Ia374a84cfdb8afdea9776e8cce5ad4e23409fe68
-rw-r--r-- | src/java/com/android/internal/telephony/SamsungQualcommRIL.java | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/java/com/android/internal/telephony/SamsungQualcommRIL.java b/src/java/com/android/internal/telephony/SamsungQualcommRIL.java index 027af5a..229444a 100644 --- a/src/java/com/android/internal/telephony/SamsungQualcommRIL.java +++ b/src/java/com/android/internal/telephony/SamsungQualcommRIL.java @@ -521,7 +521,11 @@ public class SamsungQualcommRIL extends RIL implements CommandsInterface { if (response[i]== null){ response[i]=Integer.toString(Integer.MAX_VALUE); } else { - response[i]=Integer.toString(Integer.parseInt(response[i],16)); + try { + Integer.parseInt(response[i]); + } catch(NumberFormatException e) { + response[i]=Integer.toString(Integer.parseInt(response[i],16)); + } } } } |