itchio / itch

🎮 The best way to play your itch.io games
https://itch.io/app
MIT License
2.35k stars 209 forks source link

szextractor doesn't/can't stop mid-file #2236

Open fasterthanlime opened 5 years ago

fasterthanlime commented 5 years ago

This is an issue with butler running as a daemon and large files in archives.

fasterthanlime commented 5 years ago

More info:

szextractor has a stopped state, it's only set whenever a write stream is closed:

https://github.com/itchio/boar/blob/d79a099bf1016152e04b8819224320ccf3dce2de/szextractor/szextractor.go#L392

but we could just mark the out stream as closed so that it returns 1 from outWriteGo:

https://github.com/itchio/sevenzip-go/blob/4659fbb95b944bf3e963f8b099d7deb38b806fb8/sz/glue.go#L577

and that would probably stop 7-zip dead in its tracks.