Mark all nodes as non-visited after walk through tree has completed
authorMichael Tremer <michael.tremer@ipfire.org>
Thu, 3 Oct 2019 15:30:53 +0000 (15:30 +0000)
committerMichael Tremer <michael.tremer@ipfire.org>
Thu, 3 Oct 2019 15:30:53 +0000 (15:30 +0000)
Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
src/database.c

index 37a44e5..7950b46 100644 (file)
@@ -778,7 +778,10 @@ static int loc_database_enumerator_network_depth_first_search(
        }
 
        // Reached the end of the search
-       // TODO cleanup
+
+       // Mark all nodes as non-visited
+       for (unsigned int i = 0; i < e->db->network_nodes_count; i++)
+               e->networks_visited[i] = 0;
 
        return 0;
 }