core: fix bridge port sysfs directory determination after f5507633
(platform: bridging and bonding options)
The device is not a slave if it *doesn't* have a master. Code previously returned an error if the slave did have a master, which is wrong.
This commit is contained in:
@@ -1879,7 +1879,7 @@ slave_category (NMPlatform *platform, int slave)
|
|||||||
{
|
{
|
||||||
int master = link_get_master (platform, slave);
|
int master = link_get_master (platform, slave);
|
||||||
|
|
||||||
if (master) {
|
if (master <= 0) {
|
||||||
platform->error = NM_PLATFORM_ERROR_NOT_SLAVE;
|
platform->error = NM_PLATFORM_ERROR_NOT_SLAVE;
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user