mirror of
https://github.com/seregonwar/zftpd.git
synced 2026-10-21 19:22:28 -05:00
Add platform-safe sendfile handling and build variants; bump release version and add stress test. - Makefile: introduce variant-aware build/artifact naming, ZHTTPD variant toggles, and a release-matrix target to build with/without ENABLE_ZHTTPD. - include/ftp_config.h: bump RELEASE_VERSION to "1.3.0". - src/http_api.c: guard inclusion/use of <sys/sysinfo.h> with a feature check to avoid build failures on platforms without it. - src/pal_fileio.c: tighten sendfile() error handling (return partial counts on certain storage errors, avoid retries) and document/adjust F_NOCACHE vs POSIX_FADV behavior for PS4/PS5. - src/pal_filesystem.c: add pal_fstatfs shim for PS platforms and detect unsafe filesystems (exfatfs, msdosfs, nullfs) to clear VFS_CAP_SENDFILE and avoid kernel panics when using sendfile(). - tests/stress_local.py: add a local FTP stress test that generates many small files and churns them during parallel RETR operations to help reproduce/validate robustness. These changes prevent sendfile-induced kernel panics on PS4/PS5 USB filesystems, improve error handling, and add tooling and build convenience for variant testing.