From 42d1452773a9a85b4134049d63384cf7a8bb3a68 Mon Sep 17 00:00:00 2001 From: Thomas Haller Date: Thu, 5 Oct 2017 14:45:25 +0200 Subject: [PATCH] device: fix handling NM_UNMANAGED_USER_CONF in _get_managed_by_flags() Found by clang warning: src/devices/nm-device.c:11370:14: error: use of logical '||' with constant operand [-Werror,-Wconstant-logical-operand] || NM_UNMANAGED_USER_UDEV ^ ~~~~~~~~~~~~~~~~~~~~~~ Fixes: 5778bc6a34f2291d68247695119f2170bc3bf8b3 --- src/devices/nm-device.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/devices/nm-device.c b/src/devices/nm-device.c index b81a235c3e..68ef549a3b 100644 --- a/src/devices/nm-device.c +++ b/src/devices/nm-device.c @@ -11367,8 +11367,8 @@ _get_managed_by_flags(NMUnmanagedFlags flags, NMUnmanagedFlags mask, gboolean fo * which is based on the device type. * It also overwrites the udev configuration and external-down */ flags &= ~( NM_UNMANAGED_BY_DEFAULT - || NM_UNMANAGED_USER_UDEV - || NM_UNMANAGED_EXTERNAL_DOWN); + | NM_UNMANAGED_USER_UDEV + | NM_UNMANAGED_EXTERNAL_DOWN); } if ( NM_FLAGS_HAS (mask, NM_UNMANAGED_IS_SLAVE)