summaryrefslogtreecommitdiffstats
path: root/gisi/modem.c
diff options
context:
space:
mode:
authorMika Liljeberg <mika.liljeberg@nokia.com>2010-11-25 16:52:10 +0200
committerAki Niemi <aki.niemi@nokia.com>2010-12-22 17:13:47 +0200
commit38f49a769a222b1a5227ff7bec69248bc512a3ca (patch)
tree16b432c31094ba3e6ec21bc3243c89b5ef7f60d3 /gisi/modem.c
parent11b65c55afd68ec0d8f6f8203e91ed46eeb97494 (diff)
downloadofono-38f49a769a222b1a5227ff7bec69248bc512a3ca.tar.bz2
gisi: store user data in GIsiModem
Diffstat (limited to 'gisi/modem.c')
-rw-r--r--gisi/modem.c14
1 files changed, 14 insertions, 0 deletions
diff --git a/gisi/modem.c b/gisi/modem.c
index 971d09e9..7476bef7 100644
--- a/gisi/modem.c
+++ b/gisi/modem.c
@@ -62,6 +62,7 @@ struct _GIsiModem {
guint ind_watch;
GIsiNotifyFunc debug;
void *ddata;
+ void *opaque;
};
struct _GIsiPending {
@@ -430,6 +431,19 @@ GIsiModem *g_isi_modem_create_by_name(const char *name)
return g_isi_modem_create(if_nametoindex(name));
}
+void *g_isi_modem_set_userdata(GIsiModem *modem, void *data)
+{
+ void *old = modem->opaque;
+
+ modem->opaque = data;
+ return old;
+}
+
+void *g_isi_modem_get_userdata(GIsiModem *modem)
+{
+ return modem->opaque;
+}
+
static uint8_t service_next_utid(GIsiServiceMux *mux)
{
if (mux->last_utid == 0x00 || mux->last_utid == 0xFF)