cgfsng: controller_list_is_dup()

parent 5c0089ae
......@@ -791,10 +791,9 @@ static bool controller_lists_intersect(char **l1, char **l2)
return false;
}
/*
* For a null-terminated list of controllers @clist, return true if any of
* those controllers is already listed the null-terminated list of
* hierarchies @hlist. Realistically, if one is present, all must be present.
/* For a null-terminated list of controllers @clist, return true if any of those
* controllers is already listed the null-terminated list of hierarchies @hlist.
* Realistically, if one is present, all must be present.
*/
static bool controller_list_is_dup(struct hierarchy **hlist, char **clist)
{
......@@ -802,11 +801,12 @@ static bool controller_list_is_dup(struct hierarchy **hlist, char **clist)
if (!hlist)
return false;
for (i = 0; hlist[i]; i++)
if (controller_lists_intersect(hlist[i]->controllers, clist))
return true;
return false;
return false;
}
/*
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment