aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGlenn Elliott <gelliott@cs.unc.edu>2014-08-04 16:02:30 -0400
committerGlenn Elliott <gelliott@cs.unc.edu>2014-08-04 16:02:30 -0400
commitadbb20b69e7c2947cfd83c9a4d681edb523c4dfe (patch)
tree443745fc8b5b57876a69787ccfdb5d7afdcfbd45
parent386a410e7d2735000f3403bda243a4f5ca72914d (diff)
Ancestor Test: Checking self is not an error
-rw-r--r--tools/ancestortest.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/tools/ancestortest.cpp b/tools/ancestortest.cpp
index 875894d..120085b 100644
--- a/tools/ancestortest.cpp
+++ b/tools/ancestortest.cpp
@@ -58,8 +58,8 @@ int main(void)
58 CheckError(pgm_init_edge(&e4_5, n4, n5, "e4_5")); 58 CheckError(pgm_init_edge(&e4_5, n4, n5, "e4_5"));
59 CheckError(pgm_init_backedge(&be5_0, 1, n5, n0, "be5_0")); 59 CheckError(pgm_init_backedge(&be5_0, 1, n5, n0, "be5_0"));
60 60
61 // check error case 61 // check self case
62 CheckReturn(pgm_is_ancestor(n0, n0), -1); 62 CheckReturn(pgm_is_ancestor(n0, n0), 0);
63 63
64 // all ancestors of the root? 64 // all ancestors of the root?
65 CheckReturn(pgm_is_ancestor(n1, n0), 1); 65 CheckReturn(pgm_is_ancestor(n1, n0), 1);