Hi Richard,

    list_active_contexts?  Also, since there can in theory be multiple ones
    of these, I'd do something like:

    typedef void (*ofono_gprs_active_context_cb_t)(int cid, const char *apn,
                                                     void *data);

    void (*list_active_contexts)(struct ofono_gprs *gprs,
                             ofono_gprs_active_context_cb_t active_cb,
                             ofono_gprs_cb_t finished_cb);

Nice solution, I assume we call the callback multiple times.
And if none is found we still call it once with -1 and null, right?

Well, that is what the finished_cb is for. But I guess you liked the other solution better. They're equivalent in the end.

Regards,
-Denis
_______________________________________________
ofono mailing list
[email protected]
https://lists.ofono.org/mailman/listinfo/ofono

Reply via email to