bts: Make f_power_from_band() fail in case of unknown band

Otherwise we get into weird error cases about unbound variables that are hard to debug.

Change-Id: I5716a5dc6ce95daa663be87a1a4fe611b719495e
This commit is contained in:
Harald Welte 2020-10-11 21:01:55 +02:00 committed by laforge
parent 52ae168480
commit 194b691b18
1 changed files with 3 additions and 0 deletions

View File

@ -2824,6 +2824,9 @@ private function f_power_from_band(in BtsBand band, out IntegerRecord min_dbm_le
min_dbm_level := {15};
max_dbm_level := {30};
}
case else {
Misc_Helpers.f_shutdown(__BFILE__, __LINE__, fail, "Unsupported band: " & band);
}
}
return rv;