core: fix setting device type during device creation

This commit is contained in:
Dan Williams
2009-07-07 22:25:58 -04:00
parent b62ff36e33
commit be9bc944d4
2 changed files with 5 additions and 1 deletions

View File

@@ -2248,6 +2248,10 @@ set_property (GObject *object, guint prop_id,
case NM_DEVICE_INTERFACE_PROP_MANAGED:
priv->managed = g_value_get_boolean (value);
break;
case NM_DEVICE_INTERFACE_PROP_DEVICE_TYPE:
g_return_if_fail (priv->type == NM_DEVICE_TYPE_UNKNOWN);
priv->type = g_value_get_uint (value);
break;
case NM_DEVICE_INTERFACE_PROP_TYPE_DESC:
g_free (priv->type_desc);
priv->type_desc = g_value_dup_string (value);