gprs_ns2: when calling nsvc_force_unconf for a dynamic NSE drop the NSE.
The vty command is used for test cases to reset NSE state.
So dynamic NSE shouldn't present.
Related: SYS#5208
Change-Id: I0a4f35c974c8c3b79c48f2f56170722c95254332
diff --git a/src/gb/gprs_ns2_vty2.c b/src/gb/gprs_ns2_vty2.c
index 41daa74..5af8fbc 100644
--- a/src/gb/gprs_ns2_vty2.c
+++ b/src/gb/gprs_ns2_vty2.c
@@ -1491,7 +1491,9 @@
return CMD_WARNING;
}
- if (nse->dialect == NS2_DIALECT_SNS) {
+ if (!nse->persistent) {
+ gprs_ns2_free_nse(nse);
+ } else if (nse->dialect == NS2_DIALECT_SNS) {
gprs_ns2_free_nsvcs(nse);
} else {
/* Perform the operation for all nsvc */