Keep using gzip for ncor db

This commit is contained in:
niksedk 2021-11-27 20:41:20 +01:00
parent 26945bf552
commit c52fa7ab70

View File

@ -38,7 +38,8 @@ namespace Nikse.SubtitleEdit.Logic.Ocr
File.Delete(FileName); File.Delete(FileName);
} }
using (Stream stream = new FileStream(FileName, FileMode.CreateNew, FileAccess.ReadWrite, FileShare.None)) //using (Stream stream = new FileStream(FileName, FileMode.CreateNew, FileAccess.ReadWrite, FileShare.None))
using (Stream stream = new GZipStream(File.OpenWrite(FileName), CompressionMode.Compress))
{ {
var versionBuffer = Encoding.ASCII.GetBytes(Version); var versionBuffer = Encoding.ASCII.GetBytes(Version);
stream.Write(versionBuffer, 0, versionBuffer.Length); stream.Write(versionBuffer, 0, versionBuffer.Length);