From c2874c4360be5692ead62f78b82d8ab962c8dc7b Mon Sep 17 00:00:00 2001 From: Neels Hofmeyr Date: Tue, 21 Jun 2016 19:41:30 +0200 Subject: dyn PDCH: safeguard: exit if nothing pending in dyn_pdch_ts_disconnected() The function would currently only be called in cases where one of the if branches catches on, but for safety's and clarity's sake, don't ts_connect using as_pchan if no reconnect is pending. Change-Id: I52c34065254e902bb80662fc04540901b36cb4c3 --- src/common/rsl.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'src') diff --git a/src/common/rsl.c b/src/common/rsl.c index cf6cef8b..674ce871 100644 --- a/src/common/rsl.c +++ b/src/common/rsl.c @@ -1791,7 +1791,9 @@ void dyn_pdch_ts_disconnected(struct gsm_bts_trx_ts *ts) gsm_lchan_name(ts->lchan)); ts->lchan[0].type = GSM_LCHAN_PDTCH; as_pchan = GSM_PCHAN_PDCH; - } + } else + /* No reconnect pending. */ + return; rc = bts_model_ts_connect(ts, as_pchan); /* Error? then NACK right now. */ -- cgit v1.2.3