mirror of
https://gitlab.freedesktop.org/NetworkManager/NetworkManager.git
synced 2026-05-08 13:38:43 +02:00
2008-02-10 Dan Williams <dcbw@redhat.com>
* src/nm-device-802-3-ethernet.c - (real_bring_up): save the supplicant interface state signal id - (real_bring_down): disconnect from the supplicant interface state signal git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3304 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
This commit is contained in:
parent
ce4d802a3e
commit
e476f3a6e5
2 changed files with 20 additions and 5 deletions
|
|
@ -1,3 +1,10 @@
|
||||||
|
2008-02-10 Dan Williams <dcbw@redhat.com>
|
||||||
|
|
||||||
|
* src/nm-device-802-3-ethernet.c
|
||||||
|
- (real_bring_up): save the supplicant interface state signal id
|
||||||
|
- (real_bring_down): disconnect from the supplicant interface state
|
||||||
|
signal
|
||||||
|
|
||||||
2008-02-07 Dan Williams <dcbw@redhat.com>
|
2008-02-07 Dan Williams <dcbw@redhat.com>
|
||||||
|
|
||||||
* initscript/RedHat/NetworkManager.in
|
* initscript/RedHat/NetworkManager.in
|
||||||
|
|
|
||||||
|
|
@ -56,7 +56,8 @@ typedef struct {
|
||||||
gulong link_connected_id;
|
gulong link_connected_id;
|
||||||
gulong link_disconnected_id;
|
gulong link_disconnected_id;
|
||||||
|
|
||||||
NMSupplicantInterface * sup_iface;
|
NMSupplicantInterface *sup_iface;
|
||||||
|
gulong iface_state_id;
|
||||||
} NMDevice8023EthernetPrivate;
|
} NMDevice8023EthernetPrivate;
|
||||||
|
|
||||||
enum {
|
enum {
|
||||||
|
|
@ -216,6 +217,7 @@ real_bring_up (NMDevice *dev)
|
||||||
NMDevice8023EthernetPrivate *priv = NM_DEVICE_802_3_ETHERNET_GET_PRIVATE (dev);
|
NMDevice8023EthernetPrivate *priv = NM_DEVICE_802_3_ETHERNET_GET_PRIVATE (dev);
|
||||||
NMSupplicantManager *sup_mgr;
|
NMSupplicantManager *sup_mgr;
|
||||||
const char *iface;
|
const char *iface;
|
||||||
|
gulong id;
|
||||||
|
|
||||||
iface = nm_device_get_iface (dev);
|
iface = nm_device_get_iface (dev);
|
||||||
sup_mgr = nm_supplicant_manager_get ();
|
sup_mgr = nm_supplicant_manager_get ();
|
||||||
|
|
@ -226,10 +228,11 @@ real_bring_up (NMDevice *dev)
|
||||||
return FALSE;
|
return FALSE;
|
||||||
}
|
}
|
||||||
|
|
||||||
g_signal_connect (priv->sup_iface,
|
id = g_signal_connect (priv->sup_iface,
|
||||||
"state",
|
"state",
|
||||||
G_CALLBACK (supplicant_iface_state_cb),
|
G_CALLBACK (supplicant_iface_state_cb),
|
||||||
NM_DEVICE_802_3_ETHERNET (dev));
|
NM_DEVICE_802_3_ETHERNET (dev));
|
||||||
|
priv->iface_state_id = id;
|
||||||
|
|
||||||
g_object_unref (sup_mgr);
|
g_object_unref (sup_mgr);
|
||||||
|
|
||||||
|
|
@ -245,6 +248,11 @@ real_bring_down (NMDevice *dev)
|
||||||
|
|
||||||
sup_mgr = nm_supplicant_manager_get ();
|
sup_mgr = nm_supplicant_manager_get ();
|
||||||
if (priv->sup_iface) {
|
if (priv->sup_iface) {
|
||||||
|
if (priv->iface_state_id > 0) {
|
||||||
|
g_signal_handler_disconnect (priv->sup_iface, priv->iface_state_id);
|
||||||
|
priv->iface_state_id = 0;
|
||||||
|
}
|
||||||
|
|
||||||
nm_supplicant_manager_release_iface (sup_mgr, priv->sup_iface);
|
nm_supplicant_manager_release_iface (sup_mgr, priv->sup_iface);
|
||||||
priv->sup_iface = NULL;
|
priv->sup_iface = NULL;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue