In normal operation, Phone.getLine1Number() returns an empty string if the
device doesn't know its own phone number for some reason. However the
monkey caught a case where it was returning null, which crashed the
Settings -> About Phone -> Status app.
However the javadoc for Phone.getLine1Number() *does* clearly say "May
return null if not available or the SIM is not ready", so the Status app
*should* gracefully handle this.
Now it does. (We display this case as "Unknown", just like if we get an
empty string.)
FWIW I grepped thru the rest of the code base for other uses of
getLine1Number(), and everybody else *does* handle null gracefully except
for one case in apps/Mms, which I'll open a separate bug about.
Bug: 2520977
Change-Id: I173561f903f116dbdc2b7c32b8011b59a9eb29d7
Split BluetoothDevice into BluetoothDevice and BluetoothAdapter.
BluetoothAdapter: Represents the local BT adapter. Operations on the local
adapter (start a scan, etc).
BluetoothDevice: Represents a remote BT device. Operations on remote devices
(pair, connect, etc).
Merge commit 'ed47f1e497abf5ad31b1c7035ae04478e9932986'
* commit 'ed47f1e497abf5ad31b1c7035ae04478e9932986':
Fix the NullPointerException in Status Info.
Fix bug 1964037 Phone states activity fail. It only happens in Zaku build. Zaku build overlay the device_info_status.xml under vendor/docomo and don't have CDMA related preference. Status.java will hit the NullPointerException when trying to remove the non-exist preferences.
modified: src/com/android/settings/deviceinfo/Status.java
This patch implement CDMA Settings features
1. Add code to get MEID, MIN, and PRL value if the phone is a CDMA Phone
2. Display MEID, MIN, and PRL on Settings screen if it is a CDMA phone
3. Do not display IMSI, IMEI, and IMEI SV for a CDMA phone