- Consolidate size and NUL byte checks into a single `validate_files` function to reduce I/O.
- Use `p.stat()` for early size checks before reading file content.
- Implement chunked binary reading (64KB chunks) to minimize memory footprint.
- Add early exit on NUL byte detection within chunks.
- Add OSError handling for improved robustness.
Impact: Constant memory overhead (~64KB per file) and reduced system calls during CI validation.