This is merely a historical archive of years 2008-2021, before the migration to mailman3.
A maintained and still updated list archive can be found at https://lists.osmocom.org/hyperkitty/list/gerrit-log@lists.osmocom.org/.
Harald Welte gerrit-no-reply at lists.osmocom.orgHarald Welte has submitted this change and it was merged. ( https://gerrit.osmocom.org/12049 ) Change subject: SS/USSD: fix: properly (re)schedule NCSS session timeout ...................................................................... SS/USSD: fix: properly (re)schedule NCSS session timeout It may happen that either the MS or an ESME would become unresponsive, e.g. due to a bug, or a dropped message. This is why we have SS session timeout, that prevents keeping 'stalled' sessions forever. For some reason, it wasn't properly resceduled in case of subsequent SS/USSD activity, so the lifetime of a session was limited. Let's properly (re)schedule it. Change-Id: I11aeacf012b06d3d0b5cc6e64baecf857b645fda Related: OS#3717 --- M src/hlr_ussd.c 1 file changed, 7 insertions(+), 3 deletions(-) Approvals: Harald Welte: Looks good to me, approved Jenkins Builder: Verified diff --git a/src/hlr_ussd.c b/src/hlr_ussd.c index 16a197c..cc6aa8a 100644 --- a/src/hlr_ussd.c +++ b/src/hlr_ussd.c @@ -208,10 +208,9 @@ OSMO_STRLCPY_ARRAY(ss->imsi, imsi); ss->session_id = session_id; + + /* Schedule self-destruction timer */ osmo_timer_setup(&ss->timeout, ss_session_timeout, ss); - /* NOTE: The timeout is currently not refreshed with subsequent messages - * within the SS/USSD session. So X seconds after the initial SS message, - * the session will timeout! */ if (g_hlr->ncss_guard_timeout > 0) osmo_timer_schedule(&ss->timeout, g_hlr->ncss_guard_timeout, 0); @@ -538,6 +537,11 @@ gsup->imsi, gsup->session_id); goto out_err; } + + /* Reschedule self-destruction timer */ + if (g_hlr->ncss_guard_timeout > 0) + osmo_timer_schedule(&ss->timeout, g_hlr->ncss_guard_timeout, 0); + if (ss_op_is_ussd(req.opcode)) { /* dispatch unstructured SS to routing */ handle_ussd(conn, ss, gsup, &req); -- To view, visit https://gerrit.osmocom.org/12049 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmo-hlr Gerrit-Branch: master Gerrit-MessageType: merged Gerrit-Change-Id: I11aeacf012b06d3d0b5cc6e64baecf857b645fda Gerrit-Change-Number: 12049 Gerrit-PatchSet: 4 Gerrit-Owner: Vadim Yanitskiy <axilirator at gmail.com> Gerrit-Reviewer: Harald Welte <laforge at gnumonks.org> Gerrit-Reviewer: Jenkins Builder (1000002) Gerrit-Reviewer: Pau Espin Pedrol <pespin at sysmocom.de> -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20181205/5ed394a0/attachment.htm>