mirror of
https://github.com/adamhathcock/sharpcompress.git
synced 2026-02-10 05:31:29 +00:00
Index out of range exception from gzip #408
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @xy1473210653 on GitHub (Aug 5, 2020).
my code:
using(var gzip =File.OpenWrite(dirPath))
using(var write = WriteFactory.Open(gzip,ArchiveType.GZip,new WriterOptions(CompressionType.GZip){LeaveStreamOpen = true}))
{
write.WriteAll(filePath,"*",SearchOption.AllDirectories);
}
@xy1473210653 commented on GitHub (Aug 5, 2020):
Why should compressed packages in. Tar format adopt the compression type of. Gzip
@avao commented on GitHub (Oct 13, 2020):
It looks like there is an issue with extracting file name in GZipStream.cs.
Try extracting file name in your code and supply it to Write (instead of sending full path).