summaryrefslogtreecommitdiff
path: root/src/tsort.c
diff options
context:
space:
mode:
authorJim Meyering <jim@meyering.net>2000-01-26 21:47:06 +0000
committerJim Meyering <jim@meyering.net>2000-01-26 21:47:06 +0000
commitb631b5c3aced66e4decac5e05e9547444fb3f4f0 (patch)
treea38f508f18f16afd3520a0356d22e0f2994611ac /src/tsort.c
parent06b0be15bb7773d9343b6340efe88e716b104458 (diff)
downloadcoreutils-b631b5c3aced66e4decac5e05e9547444fb3f4f0.tar.xz
(detect_loop): Update incomplete comment.
From Mark Kettenis.
Diffstat (limited to 'src/tsort.c')
-rw-r--r--src/tsort.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/src/tsort.c b/src/tsort.c
index 2097eca95..dca29189b 100644
--- a/src/tsort.c
+++ b/src/tsort.c
@@ -329,8 +329,12 @@ scan_zeros (struct item *k)
this, but that is no problem. If we encounter an item that we have
encountered before, we know that we've found a cycle. All we have
to do now is retrace our steps, printing out the items until we
- encounter that item again. (This does not have to be the item that
- we started at in the first place.) Since the order */
+ encounter that item again. (This is not necessarily the item that
+ we started from originally.) Since the order in which the items
+ are stored in the tree is not related to the specified partial
+ ordering, we may need to walk the tree several times before the
+ loop has completely been constructed. If the loop was found, the
+ global variable LOOP will be NULL. */
static int
detect_loop (struct item *k)