diff options
Diffstat (limited to 'drivers/atmodem/atutil.c')
-rw-r--r-- | drivers/atmodem/atutil.c | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/drivers/atmodem/atutil.c b/drivers/atmodem/atutil.c index ab529991..28a192a4 100644 --- a/drivers/atmodem/atutil.c +++ b/drivers/atmodem/atutil.c @@ -77,6 +77,20 @@ gint at_util_call_compare_by_phone_number(gconstpointer a, gconstpointer b) sizeof(struct ofono_phone_number)); } +gint at_util_call_compare_by_id(gconstpointer a, gconstpointer b) +{ + const struct ofono_call *call = a; + unsigned int id = GPOINTER_TO_UINT(b); + + if (id < call->id) + return -1; + + if (id > call->id) + return 1; + + return 0; +} + gint at_util_call_compare(gconstpointer a, gconstpointer b) { const struct ofono_call *ca = a; |