summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJiří Klimeš <jklimes@redhat.com>2015-05-27 11:05:38 +0200
committerJiří Klimeš <jklimes@redhat.com>2015-05-27 11:11:47 +0200
commitbfd502a9b1a2ea022218168edef13ea57a843ffc (patch)
treecd63465f5868b5af0afdb406d57730637ca0f298
parent7fe250f51d2bc285dd1992dfc2910b731cda0a92 (diff)
downloadNetworkManager-bfd502a9b1a2ea022218168edef13ea57a843ffc.tar.gz
core/cli: add missing device state-reason to string conversions
for NM_DEVICE_STATE_REASON_PARENT_CHANGED and NM_DEVICE_STATE_REASON_PARENT_MANAGED_CHANGED Fixes: cd3df12c8f8ed6c868c12bc4e7fe6ba162dafc5b
-rw-r--r--clients/cli/common.c6
-rw-r--r--src/devices/nm-device.c2
2 files changed, 8 insertions, 0 deletions
diff --git a/clients/cli/common.c b/clients/cli/common.c
index 56a7a009a8..5b07360d74 100644
--- a/clients/cli/common.c
+++ b/clients/cli/common.c
@@ -708,6 +708,12 @@ nmc_device_reason_to_string (NMDeviceStateReason reason)
case NM_DEVICE_STATE_REASON_NEW_ACTIVATION:
return _("New connection activation was enqueued");
+ case NM_DEVICE_STATE_REASON_PARENT_CHANGED:
+ return _("The device's parent changed");
+
+ case NM_DEVICE_STATE_REASON_PARENT_MANAGED_CHANGED:
+ return _("The device parent's management changed");
+
default:
/* TRANSLATORS: Unknown reason for a device state change (NMDeviceStateReason) */
return _("Unknown");
diff --git a/src/devices/nm-device.c b/src/devices/nm-device.c
index 5dbb239a7f..043d6dbe87 100644
--- a/src/devices/nm-device.c
+++ b/src/devices/nm-device.c
@@ -456,6 +456,8 @@ static const char *reason_table[] = {
[NM_DEVICE_STATE_REASON_MODEM_AVAILABLE] = "modem-available",
[NM_DEVICE_STATE_REASON_SIM_PIN_INCORRECT] = "sim-pin-incorrect",
[NM_DEVICE_STATE_REASON_NEW_ACTIVATION] = "new-activation",
+ [NM_DEVICE_STATE_REASON_PARENT_CHANGED] = "parent-changed",
+ [NM_DEVICE_STATE_REASON_PARENT_MANAGED_CHANGED] = "parent-managed-changed",
};
static const char *