From 4fb14b7c2da58de4533a9323d0fe99e9a3d004e0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rafa=C3=ABl=20Kooi?= <48814281+RA-Kooi@users.noreply.github.com> Date: Tue, 13 Sep 2022 09:40:56 +0200 Subject: [PATCH] Fix CompilationUnit's sibling being overwritten --- DwarfOne2C/Parsing/DumpParser.cs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/DwarfOne2C/Parsing/DumpParser.cs b/DwarfOne2C/Parsing/DumpParser.cs index a0bfa21..3f767e3 100644 --- a/DwarfOne2C/Parsing/DumpParser.cs +++ b/DwarfOne2C/Parsing/DumpParser.cs @@ -116,7 +116,8 @@ void FixChain(Tag parent, ref int i, int depth) if(current.tagType == TagType.End) return; - if(prev.sibling != current.ID) + if(prev.sibling != current.ID + && prev.tagType != TagType.CompileUnit) prev.sibling = current.ID; if(current.firstChild >= 0)