From fdac4cc176892734ad782dccc2dc45a0282298a2 Mon Sep 17 00:00:00 2001 From: Holger Hans Peter Freyther Date: Wed, 10 Jun 2009 11:46:58 +0200 Subject: [paging] Unbreak breakge when moving things into paging.c By calling _paging_request_stop with NULL for the lchan we have never used the paging complete callback... I didn't spot that when moving the code over and thought it is a great simplification to not call paging_request_stop first and then loop... *sigh* restore the old behaviour. Call the callback first and then free the requests. --- openbsc/src/paging.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/openbsc/src/paging.c b/openbsc/src/paging.c index e647b33be..df11da0e6 100644 --- a/openbsc/src/paging.c +++ b/openbsc/src/paging.c @@ -278,6 +278,8 @@ void paging_request_stop(struct gsm_bts *_bts, struct gsm_subscriber *subscr, { struct gsm_bts *bts = NULL; + _paging_request_stop(_bts, subscr, lchan); + do { /* * FIXME: Don't use the lac of the subscriber... @@ -290,7 +292,8 @@ void paging_request_stop(struct gsm_bts *_bts, struct gsm_subscriber *subscr, break; /* Stop paging */ - _paging_request_stop(bts, subscr, NULL); + if (bts != _bts) + _paging_request_stop(bts, subscr, NULL); } while (1); } -- cgit v1.2.3