summaryrefslogtreecommitdiffstats
path: root/telephony
diff options
context:
space:
mode:
authorNaveen Kalla <nkalla@codeaurora.org>2010-04-07 17:54:33 -0700
committerNaveen Kalla <nkalla@codeaurora.org>2010-04-12 11:16:22 -0700
commitc6dd77d04a94b7fa0659a099e5b85b70f5f2ea9f (patch)
tree320899b8b2d3be9ff7da32eaec51744c75ef06f5 /telephony
parent7bb2581e6f404da0edba9ebb81b0d0593715eb40 (diff)
downloadframeworks_base-c6dd77d04a94b7fa0659a099e5b85b70f5f2ea9f.zip
frameworks_base-c6dd77d04a94b7fa0659a099e5b85b70f5f2ea9f.tar.gz
frameworks_base-c6dd77d04a94b7fa0659a099e5b85b70f5f2ea9f.tar.bz2
telephony: Fix CID when CID is unknown
Unknown CID is indicated as 0xFFFFFFFF by ril. When telephony receives that value, set CID to UNKNOWN.
Diffstat (limited to 'telephony')
-rw-r--r--telephony/java/android/telephony/NeighboringCellInfo.java9
1 files changed, 6 insertions, 3 deletions
diff --git a/telephony/java/android/telephony/NeighboringCellInfo.java b/telephony/java/android/telephony/NeighboringCellInfo.java
index ad7dfc9..2f7666d 100644
--- a/telephony/java/android/telephony/NeighboringCellInfo.java
+++ b/telephony/java/android/telephony/NeighboringCellInfo.java
@@ -133,8 +133,11 @@ public class NeighboringCellInfo implements Parcelable
case NETWORK_TYPE_GPRS:
case NETWORK_TYPE_EDGE:
mNetworkType = radioType;
- mLac = Integer.valueOf(location.substring(0, 4), 16);
- mCid = Integer.valueOf(location.substring(4), 16);
+ // check if 0xFFFFFFFF for UNKNOWN_CID
+ if (!location.equalsIgnoreCase("FFFFFFFF")) {
+ mCid = Integer.valueOf(location.substring(4), 16);
+ mLac = Integer.valueOf(location.substring(0, 4), 16);
+ }
break;
case NETWORK_TYPE_UMTS:
case NETWORK_TYPE_HSDPA:
@@ -293,4 +296,4 @@ public class NeighboringCellInfo implements Parcelable
return new NeighboringCellInfo[size];
}
};
-} \ No newline at end of file
+}