FreeCalypso > hg > themwi-system-sw
changeset 152:7176dc850d7a
sip-in hold/retr error handling: simply send BYE
Because we know that the SIP state is CONNECTED at the time of any
such error event, we can call initiate_bye() instead of disconnect_sip(),
and thereby get rid of struct gsm_mncc_cause which will never be used
in this scenario anyway.
author | Mychaela Falconia <falcon@freecalypso.org> |
---|---|
date | Tue, 11 Oct 2022 16:11:21 -0800 |
parents | 0ecbc3dc8f93 |
children | 99fd4ae573ae |
files | sip-in/mgw_resp.c |
diffstat | 1 files changed, 2 insertions(+), 9 deletions(-) [+] |
line wrap: on
line diff
--- a/sip-in/mgw_resp.c Tue Oct 11 15:58:42 2022 -0800 +++ b/sip-in/mgw_resp.c Tue Oct 11 16:11:21 2022 -0800 @@ -14,7 +14,6 @@ #include <strings.h> #include <syslog.h> #include "../include/gsm48_const.h" -#include "../include/mncc.h" #include "../include/tmgw_ctrl.h" #include "../include/tmgw_const.h" #include "call.h" @@ -132,12 +131,6 @@ } } -static struct gsm_mncc_cause mgw_hold_retrieve_error = { - .coding = GSM48_CAUSE_CODING_GSM, - .location = GSM48_CAUSE_LOC_PRN_S_LU, - .value = GSM48_CC_CAUSE_NETWORK_OOO, -}; - static void mdcx_hold_response(call, msg) struct call *call; @@ -155,7 +148,7 @@ tmgw_send_dlcx(call); disconnect_mncc(call, GSM48_CAUSE_LOC_PRN_S_LU, GSM48_CC_CAUSE_NETWORK_OOO); - disconnect_sip(call, &mgw_hold_retrieve_error); + initiate_bye(call); } } @@ -176,7 +169,7 @@ tmgw_send_dlcx(call); disconnect_mncc(call, GSM48_CAUSE_LOC_PRN_S_LU, GSM48_CC_CAUSE_NETWORK_OOO); - disconnect_sip(call, &mgw_hold_retrieve_error); + initiate_bye(call); } }