summaryrefslogtreecommitdiffstats
path: root/gatchat/gatppp.h
diff options
context:
space:
mode:
authorDenis Kenzior <denkenz@gmail.com>2011-05-24 08:08:34 -0500
committerDenis Kenzior <denkenz@gmail.com>2011-05-24 12:25:07 -0500
commiteeb3ccc321990ddf08645e7d6a31018a9e469bcb (patch)
tree2496cba4152512e93de4945efcbc78dc7281525e /gatchat/gatppp.h
parent72dee45005812ade33f50e5400b60e3fff5f8c7f (diff)
downloadofono-eeb3ccc321990ddf08645e7d6a31018a9e469bcb.tar.bz2
gatppp: Refactor PPP API
Remove the series of constructors which take a GIOChannel directly. These weren't used. This change also allows the construction of the PPP object and filling in various pertinent information without starting the HDLC processing. The client must now use g_at_ppp_open() for the client side or g_at_ppp_listen() for the server side to start the true PPP session. The previous owner of the GAtIO object must be suspended beforehand.
Diffstat (limited to 'gatchat/gatppp.h')
-rw-r--r--gatchat/gatppp.h11
1 files changed, 5 insertions, 6 deletions
diff --git a/gatchat/gatppp.h b/gatchat/gatppp.h
index 4a27feae..f0930a77 100644
--- a/gatchat/gatppp.h
+++ b/gatchat/gatppp.h
@@ -50,13 +50,12 @@ typedef void (*GAtPPPConnectFunc)(const char *iface, const char *local,
typedef void (*GAtPPPDisconnectFunc)(GAtPPPDisconnectReason reason,
gpointer user_data);
-GAtPPP *g_at_ppp_new(GIOChannel *modem);
-GAtPPP *g_at_ppp_new_from_io(GAtIO *io);
-GAtPPP *g_at_ppp_server_new(GIOChannel *modem, const char *local);
-GAtPPP *g_at_ppp_server_new_from_io(GAtIO *io, const char *local);
-GAtPPP *g_at_ppp_server_new_full(GAtIO *io, const char *local, int fd);
+GAtPPP *g_at_ppp_new(void);
+GAtPPP *g_at_ppp_server_new(const char *local);
+GAtPPP *g_at_ppp_server_new_full(const char *local, int fd);
-void g_at_ppp_open(GAtPPP *ppp);
+gboolean g_at_ppp_open(GAtPPP *ppp, GAtIO *io);
+gboolean g_at_ppp_listen(GAtPPP *ppp, GAtIO *io);
void g_at_ppp_set_connect_function(GAtPPP *ppp, GAtPPPConnectFunc callback,
gpointer user_data);
void g_at_ppp_set_disconnect_function(GAtPPP *ppp, GAtPPPDisconnectFunc func,