Solved CDRWin plugin not working on .NET Framework and in Mono

4.0. Seems a bug in the framework implementation nonetheless,
	this workarounds satisfactorily.
This commit is contained in:
2015-05-23 05:29:35 +01:00
parent 4fc2e234b0
commit f9472ad5b9
2 changed files with 15 additions and 1 deletions

View File

@@ -1,3 +1,10 @@
2015-05-23 Natalia Portillo <claunia@claunia.com>
* ImagePlugins/CDRWin.cs:
Solved CDRWin plugin not working on .NET Framework and in
Mono 4.0. Seems a bug in the framework implementation
nonetheless, this workarounds satisfactorily.
2015-05-19 Natalia Portillo <claunia@claunia.com>
* Main.cs:

View File

@@ -457,7 +457,14 @@ namespace DiscImageChef.ImagePlugins
cuetracks = new CDRWinTrack[track_count];
line = 0;
cueStream.BaseStream.Seek(0, SeekOrigin.Begin);
// Mono <= 3.5 allowed this to work, with .Peek() NOT returning EOF.
// However .NET framework has always returned EOF even with this rewind.
// Mono 4.0 copied their bug (feature?)
//cueStream.BaseStream.Seek(0, SeekOrigin.Begin);
// Forcing me to do
cueStream.Close();
cueStream = new StreamReader(imagePath);
while (cueStream.Peek() >= 0)
{