DO NOT MERGE: Notify overall state instead of current changed state
TelephonyRegistry notifies wrong state thourgh onDataConnectionStateChanged(). As a result, browser works even though there is no data icon in status bar. The issue is reproducible as following senario: 1. There are two connections. 2. Network type is changed and one of the connections is disconnected at the same time. 3. TelephonyRegisitry notifies disconnect state to apps which are listening PhoneStateLinstener. Change-Id: Iac1e2b14e41715a63ea0d842cb44d232447e814a Signed-off-by: yoonsung.nam <yoonsung.nam@samsung.com>
This commit is contained in:
@@ -422,11 +422,13 @@ class TelephonyRegistry extends ITelephonyRegistry.Stub {
|
|||||||
modified = true;
|
modified = true;
|
||||||
}
|
}
|
||||||
if (modified) {
|
if (modified) {
|
||||||
Slog.d(TAG, "onDataConnectionStateChanged(" + state + ", " + networkType + ")");
|
Slog.d(TAG, "onDataConnectionStateChanged(" + mDataConnectionState
|
||||||
|
+ ", " + mDataConnectionNetworkType + ")");
|
||||||
for (Record r : mRecords) {
|
for (Record r : mRecords) {
|
||||||
if ((r.events & PhoneStateListener.LISTEN_DATA_CONNECTION_STATE) != 0) {
|
if ((r.events & PhoneStateListener.LISTEN_DATA_CONNECTION_STATE) != 0) {
|
||||||
try {
|
try {
|
||||||
r.callback.onDataConnectionStateChanged(state, networkType);
|
r.callback.onDataConnectionStateChanged(mDataConnectionState,
|
||||||
|
mDataConnectionNetworkType);
|
||||||
} catch (RemoteException ex) {
|
} catch (RemoteException ex) {
|
||||||
mRemoveList.add(r.binder);
|
mRemoveList.add(r.binder);
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user