Merge "[PhysicalChannelConfig] RIL will report UNKNOWN range to PhysicalChannelConfig and it can not throw out Exception." into sc-dev

This commit is contained in:
Zoey Chen
2021-01-29 02:23:24 +00:00
committed by Android (Google) Code Review

View File

@@ -554,7 +554,8 @@ public final class PhysicalChannelConfig implements Parcelable {
}
public @NonNull Builder setFrequencyRange(int frequencyRange) {
if (!ServiceState.isFrequencyRangeValid(frequencyRange)) {
if (!ServiceState.isFrequencyRangeValid(frequencyRange)
&& frequencyRange != ServiceState.FREQUENCY_RANGE_UNKNOWN) {
throw new IllegalArgumentException("Frequency range: " + frequencyRange +
" is invalid.");
}