[network-manager-applet/jk/team-bond-mtu-rh1255927: 2/3] bond: fix setting MTU for bonds when it is 0 (automatic) (rh #1177860)
- From: Jiří Klimeš <jklimes src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [network-manager-applet/jk/team-bond-mtu-rh1255927: 2/3] bond: fix setting MTU for bonds when it is 0 (automatic) (rh #1177860)
- Date: Mon, 24 Aug 2015 15:09:26 +0000 (UTC)
commit f508fc139d1e2cffb4ae000513eab4736841ea6b
Author: Jiří Klimeš <jklimes redhat com>
Date: Mon Aug 24 16:54:25 2015 +0200
bond: fix setting MTU for bonds when it is 0 (automatic) (rh #1177860)
https://bugzilla.redhat.com/show_bug.cgi?id=1177860
src/connection-editor/page-bond.c | 11 +++++------
1 files changed, 5 insertions(+), 6 deletions(-)
---
diff --git a/src/connection-editor/page-bond.c b/src/connection-editor/page-bond.c
index 02a3aee..799ea94 100644
--- a/src/connection-editor/page-bond.c
+++ b/src/connection-editor/page-bond.c
@@ -551,13 +551,12 @@ ui_to_setting (CEPageBond *self)
g_free (targets);
mtu = gtk_spin_button_get_value_as_int (priv->mtu);
- if (mtu) {
- if (!priv->wired) {
- priv->wired = NM_SETTING_WIRED (nm_setting_wired_new ());
- nm_connection_add_setting (connection, NM_SETTING (priv->wired));
- }
- g_object_set (priv->wired, NM_SETTING_WIRED_MTU, mtu, NULL);
+ if (mtu && !priv->wired) {
+ priv->wired = NM_SETTING_WIRED (nm_setting_wired_new ());
+ nm_connection_add_setting (connection, NM_SETTING (priv->wired));
}
+ if (priv->wired)
+ g_object_set (priv->wired, NM_SETTING_WIRED_MTU, mtu, NULL);
}
static gboolean
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]