Another trampoline gone.
This commit is contained in:
parent
24c6e47f07
commit
45b2d97883
@ -1724,14 +1724,24 @@ order_label_roles (const Claimlist cl)
|
||||
distance = 0;
|
||||
while (roles_remaining != NULL)
|
||||
{
|
||||
int scan_label (void *data)
|
||||
List ll;
|
||||
|
||||
distance++;
|
||||
#ifdef DEBUG
|
||||
if (DEBUGL (4))
|
||||
{
|
||||
eprintf (" %i:", distance);
|
||||
}
|
||||
#endif
|
||||
for (ll = sys->labellist; ll != NULL; ll = ll->next)
|
||||
{
|
||||
Labelinfo linfo;
|
||||
|
||||
linfo = (Labelinfo) ll->data;
|
||||
if (linfo != NULL)
|
||||
{
|
||||
Termlist tl;
|
||||
|
||||
linfo = (Labelinfo) data;
|
||||
if (linfo == NULL)
|
||||
return 1;
|
||||
tl = cl->prec;
|
||||
if (inTermlist (tl, linfo->label))
|
||||
{
|
||||
@ -1740,7 +1750,8 @@ order_label_roles (const Claimlist cl)
|
||||
// If it's not the same protocol, the labels can't match
|
||||
|
||||
// This function checks whether the newrole can connect to the connectedrole, and whether they fulfil their requirements.
|
||||
void roles_test (const Term connectedrole, const Term newrole)
|
||||
void roles_test (const Term connectedrole,
|
||||
const Term newrole)
|
||||
{
|
||||
if (inTermlist (roles_ordered, connectedrole) &&
|
||||
inTermlist (roles_remaining, newrole))
|
||||
@ -1752,7 +1763,8 @@ order_label_roles (const Claimlist cl)
|
||||
termPrint (newrole);
|
||||
}
|
||||
#endif
|
||||
roles_ordered = termlistAppend (roles_ordered, newrole);
|
||||
roles_ordered =
|
||||
termlistAppend (roles_ordered, newrole);
|
||||
roles_remaining =
|
||||
termlistDelTerm (termlistFind
|
||||
(roles_remaining, newrole));
|
||||
@ -1763,17 +1775,9 @@ order_label_roles (const Claimlist cl)
|
||||
roles_test (linfo->recvrole, linfo->sendrole);
|
||||
}
|
||||
}
|
||||
return 1;
|
||||
}
|
||||
}
|
||||
|
||||
distance++;
|
||||
#ifdef DEBUG
|
||||
if (DEBUGL (4))
|
||||
{
|
||||
eprintf (" %i:", distance);
|
||||
}
|
||||
#endif
|
||||
list_iterate (sys->labellist, scan_label);
|
||||
}
|
||||
cl->roles = roles_ordered;
|
||||
#ifdef DEBUG
|
||||
|
Loading…
Reference in New Issue
Block a user