mirror of
https://gitlab.freedesktop.org/NetworkManager/NetworkManager
synced 2024-10-07 00:31:11 +00:00
2008-03-10 Dan Williams <dcbw@redhat.com>
* src/nm-device.c - (nm_device_bring_down): deactivate the device if it's activating too, not just if it's already activated. This makes sure that everything from an association attempt is cleaned up (like DHCP for example) git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3411 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
This commit is contained in:
parent
be4addd6ae
commit
483b5f8ebd
|
@ -1,3 +1,10 @@
|
|||
2008-03-10 Dan Williams <dcbw@redhat.com>
|
||||
|
||||
* src/nm-device.c
|
||||
- (nm_device_bring_down): deactivate the device if it's activating too,
|
||||
not just if it's already activated. This makes sure that everything
|
||||
from an association attempt is cleaned up (like DHCP for example)
|
||||
|
||||
2008-03-10 Dan Williams <dcbw@redhat.com>
|
||||
|
||||
* src/nm-serial-device.c
|
||||
|
|
|
@ -1515,6 +1515,8 @@ nm_device_bring_up (NMDevice *self, gboolean wait)
|
|||
void
|
||||
nm_device_bring_down (NMDevice *self, gboolean wait)
|
||||
{
|
||||
NMDeviceState state;
|
||||
|
||||
g_return_if_fail (NM_IS_DEVICE (self));
|
||||
|
||||
if (!nm_device_is_up (self))
|
||||
|
@ -1522,7 +1524,8 @@ nm_device_bring_down (NMDevice *self, gboolean wait)
|
|||
|
||||
nm_info ("Bringing down device %s", nm_device_get_iface (self));
|
||||
|
||||
if (nm_device_get_state (self) == NM_DEVICE_STATE_ACTIVATED)
|
||||
state = nm_device_get_state (self);
|
||||
if ((state == NM_DEVICE_STATE_ACTIVATED) || nm_device_is_activating (self))
|
||||
nm_device_interface_deactivate (NM_DEVICE_INTERFACE (self));
|
||||
|
||||
if (NM_DEVICE_GET_CLASS (self)->bring_down)
|
||||
|
|
Loading…
Reference in a new issue