From b3fda81fa827b505ad3867511acfa3e4f216bda2 Mon Sep 17 00:00:00 2001 From: Matt Nadareski Date: Tue, 30 Jun 2026 16:39:29 -0400 Subject: [PATCH] Fix cloning issue with DumpMetadataSection --- .../Data/Sections/DumpMetadataSection.cs | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/SabreTools.RedumpLib/Data/Sections/DumpMetadataSection.cs b/SabreTools.RedumpLib/Data/Sections/DumpMetadataSection.cs index 21fc806..7758bd7 100644 --- a/SabreTools.RedumpLib/Data/Sections/DumpMetadataSection.cs +++ b/SabreTools.RedumpLib/Data/Sections/DumpMetadataSection.cs @@ -77,6 +77,16 @@ namespace SabreTools.RedumpLib.Data.Sections contentsSpecialFields[kvp.Key] = kvp.Value; } + Dictionary?>? fullProtections = null; + if (this.FullProtections is not null) + { + fullProtections = []; + foreach (var kvp in this.FullProtections) + { + fullProtections[kvp.Key] = kvp.Value; + } + } + return new DumpMetadataSection { Comments = this.Comments, @@ -84,12 +94,14 @@ namespace SabreTools.RedumpLib.Data.Sections Contents = this.Contents, ContentsSpecialFields = contentsSpecialFields, Protection = this.Protection, + FullProtections = fullProtections, SectorRanges = this.SectorRanges, SBI = this.SBI, PVD = this.PVD, Header = this.Header, BCA = this.BCA, PIC = this.PIC, + PICIdentifier = this.PICIdentifier, Cuesheet = this.Cuesheet, Dat = this.Dat, };