forked from enlightenment/enlightenment
batman_sysctl: Fix small logic bug for BSD systems.
We should be counting the number of instances other than the one we are deleting.
This commit is contained in:
parent
7227aaeb81
commit
72a962921c
|
@ -177,11 +177,9 @@ _batman_sysctl_stop(Instance *inst)
|
|||
if (inst->cfg->esm == E_SYSINFO_MODULE_BATMAN ||
|
||||
inst->cfg->esm == E_SYSINFO_MODULE_SYSINFO)
|
||||
{
|
||||
bat_num++;
|
||||
if (child == inst)
|
||||
if (child != inst)
|
||||
{
|
||||
bat_num--;
|
||||
break;
|
||||
bat_num++;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue