aboutsummaryrefslogtreecommitdiffstats
path: root/openbsc/src/gsm_subscriber_base.c
diff options
context:
space:
mode:
authorHolger Hans Peter Freyther <zecke@selfish.org>2009-08-22 11:18:13 +0200
committerHolger Hans Peter Freyther <zecke@selfish.org>2009-09-28 12:50:45 +0200
commit9f16a869a514500b9ede709334d67a173d59b174 (patch)
tree66ee25ac0d8f76a546f8b315721278add1babb71 /openbsc/src/gsm_subscriber_base.c
parent049935b9ccf15ec2a4762d58589e7e79bd3432fb (diff)
[subscr] subscr_paging_cb is called for expire and success
Gracefully handle a case where success and expire could fire... I'm only hitting this when doing something evil to simulate network code but it seems appropriate to handle this gracefully.
Diffstat (limited to 'openbsc/src/gsm_subscriber_base.c')
-rw-r--r--openbsc/src/gsm_subscriber_base.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/openbsc/src/gsm_subscriber_base.c b/openbsc/src/gsm_subscriber_base.c
index 54db44774..868b35599 100644
--- a/openbsc/src/gsm_subscriber_base.c
+++ b/openbsc/src/gsm_subscriber_base.c
@@ -73,7 +73,9 @@ static int subscr_paging_cb(unsigned int hooknum, unsigned int event,
struct subscr_request *request;
struct gsm_subscriber *subscr = (struct gsm_subscriber *)param;
- assert(!llist_empty(&subscr->requests));
+ /* There is no request anymore... */
+ if (llist_empty(&subscr->requests))
+ return -1;
/*
* FIXME: What to do with paging requests coming during