mirror of git://git.sysmocom.de/ofono
ppp_net: add ppp_net_suspend_interface() function
This commit is contained in:
parent
badd5555ec
commit
9fea153593
|
@ -107,6 +107,7 @@ const char *ppp_net_get_interface(struct ppp_net *net);
|
|||
void ppp_net_process_packet(struct ppp_net *net, const guint8 *packet);
|
||||
void ppp_net_free(struct ppp_net *net);
|
||||
gboolean ppp_net_set_mtu(struct ppp_net *net, guint16 mtu);
|
||||
void ppp_net_suspend_interface(struct ppp_net *net);
|
||||
|
||||
/* PPP functions related to main GAtPPP object */
|
||||
void ppp_debug(GAtPPP *ppp, const char *str);
|
||||
|
|
|
@ -196,3 +196,12 @@ void ppp_net_free(struct ppp_net *net)
|
|||
g_free(net->if_name);
|
||||
g_free(net);
|
||||
}
|
||||
|
||||
void ppp_net_suspend_interface(struct ppp_net *net)
|
||||
{
|
||||
if (net == NULL || net->channel == NULL)
|
||||
return;
|
||||
|
||||
if (net->watch)
|
||||
g_source_remove(net->watch);
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue