summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorHolger Hans Peter Freyther <holger@moiji-mobile.com>2015-06-20 18:45:35 +0200
committerHolger Hans Peter Freyther <holger@moiji-mobile.com>2015-06-20 18:45:35 +0200
commit57ee78078905c7499bd4e6857f8981d22badfcac (patch)
tree4ab5968d2630a44c4116a13d61fd825d7b2a1be8
parent797eb7b592e2912ef3e12dbac415f6fa9d444ab9 (diff)
bts: Arfcn can never be smaller than 0
Remove the condition because it can never be true. Fixes: Coverity CID#1307793
-rw-r--r--openbsc/src/libbsc/bsc_init.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/openbsc/src/libbsc/bsc_init.c b/openbsc/src/libbsc/bsc_init.c
index a63528c..46d95cc 100644
--- a/openbsc/src/libbsc/bsc_init.c
+++ b/openbsc/src/libbsc/bsc_init.c
@@ -397,8 +397,7 @@ static int bootstrap_bts(struct gsm_bts *bts)
}
break;
case GSM_BAND_900:
- if (bts->c0->arfcn < 0 ||
- (bts->c0->arfcn > 124 && bts->c0->arfcn < 955) ||
+ if ((bts->c0->arfcn > 124 && bts->c0->arfcn < 955) ||
bts->c0->arfcn > 1023) {
LOGP(DNM, LOGL_ERROR, "GSM900 channel must be between 0-124, 955-1023.\n");
return -EINVAL;