Quoting Holger Hans Peter Freyther (2014-09-01 13:45:02)
On Sun, Aug 31, 2014 at 05:13:15PM -0500, Ruben Pollan wrote:
+ if (subscr->use_count != 1) { + vty_out(vty, "Removing active subscriber%s", VTY_NEWLINE); + }
You could write abort() as well. You should return CMD_ERROR or such as you can't remove an active subscriber.
This code is basically copied from openbsc/src/libmsc/ctrl_commands.c where is doing: if (subscr->use_count != 1) { LOGP(DCTRL, LOGL_NOTICE, "Going to remove active subscriber.\n"); was_used = 1; } rc = db_subscriber_delete(subscr); In the ctrl commands interface even if is in use it keeps trying to delete it. Maybe I'm missing something and the two interfaces should behave differently, or it's a bug on the ctrl interface.
+ # Delte it
Delete
Ok. -- Ruben Pollan | http://meskio.net/ -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=- My contact info: http://meskio.net/crypto.txt -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=- Nos vamos a Croatan.