[calls] Remove a tautology from gsm48_cc_rx_disconnect

We directly assign the call->state and then check for something
that will never be true, and then immediately put the lchan and
schedule it's disconnect... and then directly after having closed
it down we send a message...

Change this to uncondtionally put down the lchan after having
changed the last(?) command.
This commit is contained in:
Holger Freyther 2009-04-12 04:36:16 +00:00
parent 0469cf608b
commit 3190a89e38
1 changed files with 1 additions and 2 deletions

View File

@ -1202,12 +1202,11 @@ static int gsm48_cc_rx_disconnect(struct msgb *msg)
/* Section 5.4.3.2 */
DEBUGP(DCC, "A -> DISCONNECT (state->RELEASE_REQ)\n");
call->state = GSM_CSTATE_RELEASE_REQ;
if (call->state != GSM_CSTATE_NULL)
put_lchan(msg->lchan);
/* FIXME: clear the network connection */
DEBUGP(DCC, "A <- RELEASE\n");
rc = gsm48_tx_simple(msg->lchan, GSM48_PDISC_CC,
GSM48_MT_CC_RELEASE);
put_lchan(msg->lchan);
/* forward DISCONNECT to other party */
if (!call->remote_lchan)