mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-10 03:45:46 +00:00
Followup to bug 559898: fix cycle checker to allow self-loop special case.
This commit is contained in:
parent
574b849ecd
commit
a945d618e9
@ -958,6 +958,10 @@ def checkcycles(p, stack=None):
|
|||||||
stack = []
|
stack = []
|
||||||
|
|
||||||
for cp in p.manages:
|
for cp in p.manages:
|
||||||
|
# special case for self-managed protocols
|
||||||
|
if cp is p:
|
||||||
|
continue
|
||||||
|
|
||||||
if cp in stack:
|
if cp in stack:
|
||||||
return [stack + [p, cp]]
|
return [stack + [p, cp]]
|
||||||
cycles += checkcycles(cp, stack + [p])
|
cycles += checkcycles(cp, stack + [p])
|
||||||
|
Loading…
Reference in New Issue
Block a user