Releases: CalebQ42/squashfs
ReaderAtOffset
- Added ReaderAtOffset which reads a squashfs archive from io.ReaderAt at a given offset.
Slight FUSE improvements
squashfs.Mount
now serves the mount on a seperate goroutine and has comments.
FUSE
Clean before validating path
Paths passed to squashfs.FS
are now cleaned before they are validated. This is to fix an issue I found where a valid symlink was being rejected due to the path starting with ./
Fragments work properly
Fixed a couple issues with fragments. Particularly:
- If you had more then 512 fragments then it would start using ID table numbers (oops) (thanks @tri-adam)
- Some fragments would not be read from deep enough into the fragment
Additional Fixes:
- FS.ReadDir, FS.Glob, and FS.Stat would throw type assertion errors. (Again, thanks @tri-adam)
What's Changed
Full Changelog: v0.6.0...v0.6.1
Mainly just some code work
Ideally this release does basically nothing, it's just a large re-write of many parts of the code to make it more maintainable and understandable. This does fix one bug (#15 and #14) relating to how fragments are read and processed.
There are some breaking changes.
- NewSquashfsReader and NewSquashfsReaderFromReader have been renamed to NewReader and NewReaderFromReader.
- This better matches other libraries.
- Reader.Init() was removed. This was never meant to be exported and shouldn't have been used.
- FileInfo and DirEntry is not longer exported. They were identical in functionality to fs.FileInfo and fs.DirEntry so it felt unnecessary to export them as separate structs.
This release should be good, but due to the large amount of changes (and the fact I apparently finished it a month ago, then go COVID and completely forgot about it) I recommend caution when upgrading to it.
Handle paths with special characters
Changed Open
, ReadDir
, Stat
, and Sub
to only accept exact matches. Allowing wildcards by using path.Match
causes issues in certain circumstances. You can use fs.Glob
if you need to use wildcards, and I'll probably implement fs.GlobFS
at some point in the near (ish) future.
What's Changed
New Contributors
Full Changelog: v0.5.3...v0.5.4
Added "." directory support.
Added support for "." as a directory thanks to @stffabi
Fixed io.Reader support
Fixed some issues I was having with io.Readers and squashfs archives
io.Reader support
You can now use an io.Reader to create a squashfs.Reader. This is not recommended, especially for large archives since almost all of the archive WILL end up cached in memory.