0b994ff1c3325cf78f278552da32cdb3cfb7e531
Put and PutFile added the blob size to s.total before writing, and only the writeFile and os.Rename failure paths released it. A writeMeta failure in either, and a chmod failure on the spool in PutFile, kept the size, so a store that hit a full disk over-counted itself and could answer ErrStoreFull while the disk had room until the next Open re-measured. One defer per function now owns the release, disarmed on the success return, so a future early return cannot reintroduce the leak. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Description
No description provided
Languages
Go
97.1%
HTML
0.9%
Shell
0.6%
CSS
0.5%
Makefile
0.3%
Other
0.6%