From 54127004d85b3bcd09eaf03f2790725b91eddece Mon Sep 17 00:00:00 2001 From: John Whitington Date: Mon, 28 Oct 2024 14:09:01 +0000 Subject: [PATCH] Preserve nested stags --- cpdfdraw.ml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cpdfdraw.ml b/cpdfdraw.ml index da05783..b39495f 100644 --- a/cpdfdraw.ml +++ b/cpdfdraw.ml @@ -655,7 +655,7 @@ let rec find_tree_contents a level = function | StDataBeginTree _ as h::t -> find_tree_contents (h::a) (level + 1) t | StDataEndTree::t -> - if level = 1 then (rev a, t) else find_tree_contents a (level - 1) t + if level = 1 then (rev a, t) else find_tree_contents (StDataEndTree::a) (level - 1) t | h::t -> find_tree_contents (h::a) level t let mstdebug = ref false