adamhathcock / sharpcompress

SharpCompress is a fully managed C# library to deal with many compression types and formats.
MIT License
2.24k stars 480 forks source link

Sharpcompress not read all entries using TarArchive #90

Open kalpesh2804 opened 8 years ago

kalpesh2804 commented 8 years ago

I added 10,000 files in 2 different folder but below sample can read only 1 folder. sample code:

        using (Stream stream = File.Open(FileName, FileMode.Open, FileAccess.ReadWrite, FileShare.ReadWrite))
        {
            if (TarArchive.IsTarFile(stream))
            {
                stream.Seek(0, SeekOrigin.Begin);
                objTar = TarArchive.Open(stream);

                foreach (var tarEnt in objTar.Entries)
                {
                    if (!tarEnt.IsDirectory)
                    {
                        lstFiles.Add(tarEnt.FilePath);
                        FileList.Add(tarEnt);
                    }
                }
            }
        }
adamhathcock commented 8 years ago

Do you have a sample file for me to test with? Hopefully a small one.

kalpesh2804 commented 8 years ago

Its creating issue in large file (approx. 1 GB). if you want i will try to prepare it and upload it.

adamhathcock commented 8 years ago

I guess I'm better off trying to recreate it.

kalpesh2804 commented 8 years ago

did you reproduce this error ?

adamhathcock commented 8 years ago

I likely won't have time any time soon to actual code or debug anything.