From 0611c508bc7156c4faa9bf6451c8a344b6666e08 Mon Sep 17 00:00:00 2001 From: Natalia Portillo Date: Wed, 30 Jun 2021 22:32:11 +0100 Subject: [PATCH] Move detection of missing data from multisession CDRWin images to after we know if it is a CD image or not. --- Aaru.Images/CDRWin/Read.cs | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/Aaru.Images/CDRWin/Read.cs b/Aaru.Images/CDRWin/Read.cs index 36403130b..8a341a09c 100644 --- a/Aaru.Images/CDRWin/Read.cs +++ b/Aaru.Images/CDRWin/Read.cs @@ -822,12 +822,6 @@ namespace Aaru.DiscImages } } - if(currentSession > 1 && - leadouts.Count == 0 && - !_discImage.IsRedumpGigadisc) - throw new - FeatureUnsupportedImageException("This image is missing vital multi-session data and cannot be read correctly."); - if(currentTrack.Sequence != 0) { currentFile.Sequence = currentTrack.Sequence; @@ -1493,6 +1487,13 @@ namespace Aaru.DiscImages (mediaTypeAsInt >= 171 && mediaTypeAsInt <= 179) || (mediaTypeAsInt >= 740 && mediaTypeAsInt <= 749); + if(currentSession > 1 && + leadouts.Count == 0 && + !_discImage.IsRedumpGigadisc && + _isCd) + throw new + FeatureUnsupportedImageException("This image is missing vital multi-session data and cannot be read correctly."); + if(!_isCd) { _imageInfo.ReadableSectorTags.Remove(SectorTagType.CdSectorSync);