From d241f9826298898619f6ed1841d31d6a9288c99d Mon Sep 17 00:00:00 2001 From: Harald Welte Date: Wed, 9 May 2018 20:03:38 +0200 Subject: rsl: If CHAN ACT or MODE MODIF fails, send respective NACK The existign code only sent an ERROR REPORT, but it failed to actually send a proper NACK to the related request. This is confusing, as the operation should always be ACKed or NACKed, and not simply result in no response. Change-Id: Ic374a8e5e239ffe37082a54cdb94cb6ac9723e83 Closes: OS#3254 --- src/common/rsl.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'src/common/rsl.c') diff --git a/src/common/rsl.c b/src/common/rsl.c index 4d8279c0..5dd2c59f 100644 --- a/src/common/rsl.c +++ b/src/common/rsl.c @@ -1032,8 +1032,8 @@ static int rsl_rx_chan_activ(struct msgb *msg) const uint8_t *val = TLVP_VAL(&tp, RSL_IE_ENCR_INFO); if (encr_info2lchan(lchan, val, len) < 0) { - return rsl_tx_error_report(msg->trx, RSL_ERR_IE_CONTENT, - &dch->chan_nr, NULL, msg); + rsl_tx_error_report(msg->trx, RSL_ERR_IE_CONTENT, &dch->chan_nr, NULL, msg); + return rsl_tx_chan_act_acknack(lchan, RSL_ERR_ENCR_UNIMPL); } } else memset(&lchan->encr, 0, sizeof(lchan->encr)); @@ -1476,8 +1476,8 @@ static int rsl_rx_mode_modif(struct msgb *msg) const uint8_t *val = TLVP_VAL(&tp, RSL_IE_ENCR_INFO); if (encr_info2lchan(lchan, val, len) < 0) { - return rsl_tx_error_report(msg->trx, RSL_ERR_IE_CONTENT, &dch->chan_nr, - NULL, msg); + rsl_tx_error_report(msg->trx, RSL_ERR_IE_CONTENT, &dch->chan_nr, NULL, msg); + return rsl_tx_mode_modif_nack(lchan, RSL_ERR_ENCR_UNIMPL); } } -- cgit v1.2.3