diff options
author | Bastien Montagne <montagne29@wanadoo.fr> | 2014-12-01 16:33:38 +0300 |
---|---|---|
committer | Bastien Montagne <montagne29@wanadoo.fr> | 2014-12-01 19:11:55 +0300 |
commit | 9c782c17ba03b3ed61bec1f1e9c73bc5f6522ded (patch) | |
tree | f5421e85d8871424a47a948851c0091046c7a243 /source/blender/blenlib/intern/graph.c | |
parent | f2c3b5a384f064b5ebbc5c0b74adf5bfa6ec11fb (diff) |
Cleanup: hopefully last int->bool one in this area!
Diffstat (limited to 'source/blender/blenlib/intern/graph.c')
-rw-r--r-- | source/blender/blenlib/intern/graph.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/source/blender/blenlib/intern/graph.c b/source/blender/blenlib/intern/graph.c index d4d87dfdbf6..81cc9fde01f 100644 --- a/source/blender/blenlib/intern/graph.c +++ b/source/blender/blenlib/intern/graph.c @@ -170,11 +170,11 @@ bool BLI_hasAdjacencyList(BGraph *graph) for (node = graph->nodes.first; node; node = node->next) { if (node->arcs == NULL) { - return 0; + return false; } } - return 1; + return true; } void BLI_replaceNodeInArc(BGraph *graph, BArc *arc, BNode *node_src, BNode *node_replaced) @@ -337,7 +337,7 @@ static bool detectCycle(BNode *node, BArc *src_arc) } } else { - value = 1; + value = true; } return value; @@ -354,7 +354,7 @@ bool BLI_isGraphCyclic(BGraph *graph) BLI_flagNodes(graph, 0); /* detectCycles in subgraphs */ - for (node = graph->nodes.first; node && value == 0; node = node->next) { + for (node = graph->nodes.first; node && value == false; node = node->next) { /* only for nodes in subgraphs that haven't been visited yet */ if (node->flag == 0) { value = value || detectCycle(node, NULL); |