Skip to content

Commit fb90081

Browse files
author
Catherine Liu
committed
Fix wrong count return for getPhoneSignalStrengthCount
Test report for the time spent in each signal strength bin, along with the number of times that bin was entered showed the result as Bin=3 Time=3211926000 Count=0. With a non-zero Time, the Count value 0 was wrong. The cause of the problem was that getPhoneSignalStrengthCount() used mPhoneDataConnectionsTimer, instead of mPhoneSignalStrengthsTimer, to get the count. Change-Id: I55ac1125abfcfdc105605d76d1c706ac315b90cc
1 parent 3c04cc4 commit fb90081

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

core/java/com/android/internal/os/BatteryStatsImpl.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2302,8 +2302,8 @@ public void noteNetworkInterfaceTypeLocked(String iface, int networkType) {
23022302
batteryRealtime, which);
23032303
}
23042304

2305-
@Override public int getPhoneSignalStrengthCount(int dataType, int which) {
2306-
return mPhoneDataConnectionsTimer[dataType].getCountLocked(which);
2305+
@Override public int getPhoneSignalStrengthCount(int strengthBin, int which) {
2306+
return mPhoneSignalStrengthsTimer[strengthBin].getCountLocked(which);
23072307
}
23082308

23092309
@Override public long getPhoneDataConnectionTime(int dataType,

0 commit comments

Comments
 (0)