commit | 5b72b30877d6449bcf4f5053e20205eff44dade1 | [log] [tgz] |
---|---|---|
author | Holger Hans Peter Freyther <zecke@selfish.org> | Tue Dec 28 22:12:30 2010 +0100 |
committer | Holger Hans Peter Freyther <zecke@selfish.org> | Thu Jan 06 14:52:52 2011 +0100 |
tree | cb0e60feb027a194e818df2248c537b4e97edde2 | |
parent | a32e9c19e8ed3805ad9298d50fc3840e6176d47e [diff] [blame] |
subscr: Show the number of pending requests on this subscriber.
diff --git a/openbsc/src/gsm_subscriber.c b/openbsc/src/gsm_subscriber.c index 1326021..f42c688 100644 --- a/openbsc/src/gsm_subscriber.c +++ b/openbsc/src/gsm_subscriber.c
@@ -345,3 +345,14 @@ { db_subscriber_update(sub); } + +int subscr_pending_requests(struct gsm_subscriber *sub) +{ + struct subscr_request *req; + int pending = 0; + + llist_for_each_entry(req, &sub->requests, entry) + pending += 1; + + return pending; +}