Add EWAD format, status codes and embeddable build #1
Loading…
Reference in a new issue
No description provided.
Delete branch "fputs/ewad"
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?
Summary
EWADtype: 63-byte names, duplicate lumps in insertion order, deterministic output, and strict validation on load.Lump.kind.wad_status_name.fseek/ftell/empty-file handling.add_subdirectory: CMake 3.17, C11,SPITWAD_SANITIZE, and tests only when top-level. Adds an MIT LICENSE.docs/spitwad.mdanddocs/WAD Format.md, and a CI job that runs the tests under ASan and UBSan.Behaviour changes
wad_load_fileandwad_load_datado not needwad_initand do not free what the WAD held. Callwad_destroybefore reloading a populated WAD.SPITWAD_ERR_MALFORMEDif lumps total more than 16 times the input size or more thanUINT32_MAXbytes, which bounds memory use on crafted files.SPITWAD_ERR_UNSUPPORTED. Status codes also includeSPITWAD_ERR_NOT_FOUNDandSPITWAD_ERR_TOO_LARGE.Testing
SPITWAD_SANITIZE=ON, on macOS and on Alpine 3.24 with leak detection on.Known gaps
PACKsignature are parsed with the classic layout, so real PAK files are misread.🤖 Generated with Claude Code