diff options
| author | Michael Biebl <biebl@debian.org> | 2018-07-03 23:54:48 +0200 |
|---|---|---|
| committer | Michael Biebl <biebl@debian.org> | 2018-07-03 23:54:48 +0200 |
| commit | 54de7f04d1fac5f29fd54ec4120ba2fc4f9b5714 (patch) | |
| tree | 87729385ff8de744dc44d0b4cc75916494b2fd38 /libnm-core/nm-setting-ovs-patch.c | |
| parent | 680d3db45106e7a18665a366e1b57e58cef61506 (diff) | |
| parent | 329b15110c4b183d7a47552abe3a6a6ff933e817 (diff) | |
Merge branch 'experimental'
Diffstat (limited to 'libnm-core/nm-setting-ovs-patch.c')
| -rw-r--r-- | libnm-core/nm-setting-ovs-patch.c | 14 |
1 files changed, 5 insertions, 9 deletions
diff --git a/libnm-core/nm-setting-ovs-patch.c b/libnm-core/nm-setting-ovs-patch.c index 9e380914..980015f2 100644 --- a/libnm-core/nm-setting-ovs-patch.c +++ b/libnm-core/nm-setting-ovs-patch.c @@ -28,10 +28,10 @@ /** * SECTION:nm-setting-ovs-patch - * @short_description: Describes connection properties for OpenVSwitch patch interfaces. + * @short_description: Describes connection properties for Open vSwitch patch interfaces. * * The #NMSettingOvsPatch object is a #NMSetting subclass that describes properties - * necessary for OpenVSwitch interfaces of type "patch". + * necessary for Open vSwitch interfaces of type "patch". **/ enum { @@ -83,7 +83,6 @@ static int verify (NMSetting *setting, NMConnection *connection, GError **error) { NMSettingOvsPatch *self = NM_SETTING_OVS_PATCH (setting); - int family = AF_UNSPEC; if (!_nm_connection_verify_required_interface_name (connection, error)) return FALSE; @@ -99,11 +98,8 @@ verify (NMSetting *setting, NMConnection *connection, GError **error) return FALSE; } - if (nm_utils_ipaddr_valid (AF_INET, self->peer)) - family = AF_INET; - else if (nm_utils_ipaddr_valid (AF_INET6, self->peer)) - family = AF_INET6; - else { + if ( !nm_utils_ipaddr_valid (AF_INET, self->peer) + && !nm_utils_ipaddr_valid (AF_INET6, self->peer)) { g_set_error (error, NM_CONNECTION_ERROR, NM_CONNECTION_ERROR_INVALID_PROPERTY, @@ -199,7 +195,7 @@ nm_setting_ovs_patch_class_init (NMSettingOvsPatchClass *setting_class) /** * NMSettingOvsPatch:peer: * - * Specifies the unicast destination IP address of a remote OpenVSwitch + * Specifies the unicast destination IP address of a remote Open vSwitch * bridge port to connect to. * * Since: 1.10 |