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/.
laforge gerrit-no-reply at lists.osmocom.orglaforge has submitted this change and it was merged. ( https://gerrit.osmocom.org/c/osmo-ggsn/+/15259 ) Change subject: libgtp: announce pdp ctx deletion upon CreatePdpCtx being rejected ...................................................................... libgtp: announce pdp ctx deletion upon CreatePdpCtx being rejected The libgtp application may have already allocated related resources associated to the pdp context, so we need to signal its deletion in order to let the application free the resources. This should fix the duplication of pdp contexts seen in osmo-ggsn when "show pdp-context" related VTY commands are used. It was spotted due to some MS requesting a v4v6 context on a v4-only APN, where first v4 address was allocated, and then upon v6 allocation create_context_ind() called gtp_create_context_resp(GTPCAUSE_MISSING_APN) but the first address was not freed. Upon receiving the callback, osmo-ggsn should now free the related resources. Related: OS#4154 Change-Id: I6c6215a4ce478afabc78ffaf5ffb0cf829e41226 --- M ggsn/ggsn.c M gtp/gtp.c 2 files changed, 3 insertions(+), 4 deletions(-) Approvals: Jenkins Builder: Verified osmith: Looks good to me, approved laforge: Looks good to me, but someone else must approve diff --git a/ggsn/ggsn.c b/ggsn/ggsn.c index 95371a2..d71855d 100644 --- a/ggsn/ggsn.c +++ b/ggsn/ggsn.c @@ -386,7 +386,7 @@ LOGPPDP(LOGL_ERROR, pdp, "Cannot find/free IP Pool member\n"); } - if (apn->cfg.gtpu_mode == APN_GTPU_MODE_KERNEL_GTP) { + if (apn && apn->cfg.gtpu_mode == APN_GTPU_MODE_KERNEL_GTP) { if (gtp_kernel_tunnel_del(pdp, apn->tun.cfg.dev_name)) { LOGPPDP(LOGL_ERROR, pdp, "Cannot delete tunnel from kernel:%s\n", strerror(errno)); diff --git a/gtp/gtp.c b/gtp/gtp.c index 799f8a7..f0318f7 100644 --- a/gtp/gtp.c +++ b/gtp/gtp.c @@ -1301,9 +1301,8 @@ /* Now send off a reply to the peer */ gtp_create_pdp_resp(gsn, pdp->version, pdp, cause); - if (cause != GTPCAUSE_ACC_REQ) { - pdp_freepdp(pdp); - } + if (cause != GTPCAUSE_ACC_REQ) + gtp_freepdp(gsn, pdp); return 0; } -- To view, visit https://gerrit.osmocom.org/c/osmo-ggsn/+/15259 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmo-ggsn Gerrit-Branch: master Gerrit-Change-Id: I6c6215a4ce478afabc78ffaf5ffb0cf829e41226 Gerrit-Change-Number: 15259 Gerrit-PatchSet: 2 Gerrit-Owner: pespin <pespin at sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: keith <keith at rhizomatica.org> Gerrit-Reviewer: laforge <laforge at gnumonks.org> Gerrit-Reviewer: lynxis lazus <lynxis at fe80.eu> Gerrit-Reviewer: osmith <osmith at sysmocom.de> Gerrit-Reviewer: pespin <pespin at sysmocom.de> Gerrit-MessageType: merged -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20190827/f6ab18cc/attachment.htm>