supplicant: handle interface state 'disabled'

Been around for a while; happens if the interface goes away or is
rfkilled.  Recognize it for now but we don't do anything with it
yet.
This commit is contained in:
Dan Williams 2012-05-11 17:15:40 -05:00
parent 4d74277edd
commit c3d3a3d16a
2 changed files with 6 additions and 1 deletions

View file

@ -369,7 +369,9 @@ wpas_iface_bss_removed (DBusGProxy *proxy,
static int
wpas_state_string_to_enum (const char *str_state)
{
if (!strcmp (str_state, "disconnected"))
if (!strcmp (str_state, "interface_disabled"))
return NM_SUPPLICANT_INTERFACE_STATE_DISABLED;
else if (!strcmp (str_state, "disconnected"))
return NM_SUPPLICANT_INTERFACE_STATE_DISCONNECTED;
else if (!strcmp (str_state, "inactive"))
return NM_SUPPLICANT_INTERFACE_STATE_INACTIVE;
@ -1290,6 +1292,8 @@ nm_supplicant_interface_state_to_string (guint32 state)
return "starting";
case NM_SUPPLICANT_INTERFACE_STATE_READY:
return "ready";
case NM_SUPPLICANT_INTERFACE_STATE_DISABLED:
return "disabled";
case NM_SUPPLICANT_INTERFACE_STATE_DISCONNECTED:
return "disconnected";
case NM_SUPPLICANT_INTERFACE_STATE_INACTIVE:

View file

@ -34,6 +34,7 @@ enum {
NM_SUPPLICANT_INTERFACE_STATE_INIT = 0,
NM_SUPPLICANT_INTERFACE_STATE_STARTING,
NM_SUPPLICANT_INTERFACE_STATE_READY,
NM_SUPPLICANT_INTERFACE_STATE_DISABLED,
NM_SUPPLICANT_INTERFACE_STATE_DISCONNECTED,
NM_SUPPLICANT_INTERFACE_STATE_INACTIVE,
NM_SUPPLICANT_INTERFACE_STATE_SCANNING,