pespin has submitted this change. ( 
https://gerrit.osmocom.org/c/libosmo-sigtran/+/41500?usp=email )

Change subject: ss7_xua_server_destroy(): Disconnect streams properly
......................................................................

ss7_xua_server_destroy(): Disconnect streams properly

destroying ASPs is wrong, since that'd also destroy non-dynamic ASPs,
hence erasing the configuration.
Instead, close oly the stream, and dynamic ASPs get destroyed as a
consequence.

Change-Id: I1309015053d2bd22d8fdf6298f8918a47527340e
---
M src/ss7_xua_srv.c
1 file changed, 5 insertions(+), 3 deletions(-)

Approvals:
  Jenkins Builder: Verified
  fixeria: Looks good to me, approved
  osmith: Looks good to me, but someone else must approve




diff --git a/src/ss7_xua_srv.c b/src/ss7_xua_srv.c
index 077eea0..a97b07f 100644
--- a/src/ss7_xua_srv.c
+++ b/src/ss7_xua_srv.c
@@ -397,11 +397,13 @@
        if (xs->server) {
                osmo_stream_srv_link_close(xs->server);
                osmo_stream_srv_link_destroy(xs->server);
+               xs->server = NULL;
        }
-       /* iterate and close all connections established in relation
-        * with this server */
+
+       /* iterate and close all connections established in relation with this 
server.
+        * Dynamic ASPs in SCTP=server are destroyed when connection is closed. 
*/
        llist_for_each_entry_safe(asp, asp2, &xs->asp_list, siblings)
-               osmo_ss7_asp_destroy(asp);
+               ss7_asp_disconnect_stream(asp);

        llist_del(&xs->list);
        talloc_free(xs);

--
To view, visit https://gerrit.osmocom.org/c/libosmo-sigtran/+/41500?usp=email
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings?usp=email

Gerrit-MessageType: merged
Gerrit-Project: libosmo-sigtran
Gerrit-Branch: master
Gerrit-Change-Id: I1309015053d2bd22d8fdf6298f8918a47527340e
Gerrit-Change-Number: 41500
Gerrit-PatchSet: 2
Gerrit-Owner: pespin <[email protected]>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: fixeria <[email protected]>
Gerrit-Reviewer: osmith <[email protected]>
Gerrit-Reviewer: pespin <[email protected]>

Reply via email to