Close files, GC can take too long and the OS will trash us.

This commit is contained in:
2014-07-03 18:31:27 +01:00
parent ded61b9f99
commit 3cbb84be7f
3 changed files with 11 additions and 0 deletions

View File

@@ -215,6 +215,7 @@ namespace DiscImageChef.ImagePlugins
FileStream stream = new FileStream(imagePath, FileMode.Open, FileAccess.Read);
stream.Read(headerBytes, 0, 12);
stream.Close();
header.signature = BitConverter.ToUInt16(headerBytes, 0);
@@ -564,6 +565,7 @@ namespace DiscImageChef.ImagePlugins
biggestSectorSize = (uint)decodedData.Length;
}
}
stream.Close();
return true;
}