From ce29d7d6262c8ba2e258b36794992ec79feb6e1f Mon Sep 17 00:00:00 2001 From: marcofleon Date: Fri, 12 Dec 2025 13:35:49 +0000 Subject: [PATCH] fuzz: Fix variable in `clusterlin_postlinearize_tree` check The test intends to verify that running `PostLinearize` a second time on a tree-structured graph doesn't change the result. But `PostLinearize` was being called on the original variable, not the copy. So the check was comparing the unmodified copy against itself, which is useless. Fix by post-linearizing the correct variable. --- src/test/fuzz/cluster_linearize.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/test/fuzz/cluster_linearize.cpp b/src/test/fuzz/cluster_linearize.cpp index 86734591d99..d2286caee55 100644 --- a/src/test/fuzz/cluster_linearize.cpp +++ b/src/test/fuzz/cluster_linearize.cpp @@ -1309,8 +1309,8 @@ FUZZ_TARGET(clusterlin_postlinearize_tree) // Verify that post-linearizing again does not change the diagram. The result must be identical // as post_linearization ought to be optimal already with a tree-structured graph. auto post_post_linearization = post_linearization; - PostLinearize(depgraph_tree, post_linearization); - SanityCheck(depgraph_tree, post_linearization); + PostLinearize(depgraph_tree, post_post_linearization); + SanityCheck(depgraph_tree, post_post_linearization); auto post_post_chunking = ChunkLinearization(depgraph_tree, post_post_linearization); auto cmp_post = CompareChunks(post_post_chunking, post_chunking); assert(cmp_post == 0);