Files
libfreemkv/docs/platform-macos.md
T
Matthew Jackson 6e14fc0c0c libfreemkv: 1.7.0 groundwork — sector-recycle soundness + CI hardening
Security
- Remove the unsafe Vec::set_len over recycled sector buffers — UB reachable
  from safe code (GHSA-j8ww-f5fg-9pmh, low). Uses Vec::resize; pooling unchanged.

CI / tooling
- clippy on stable with the MSRV single-sourced from Cargo.toml; cargo-deny
  dependency-audit gate with first-party git sources allowed (#15); audience-based
  comment-guard (#17).

Docs
- README (keydb ownership, BD-J parser count), drive-access transport/reset
  notes, mux timeline module-doc links.
2026-09-02 12:40:55 -07:00

13 lines
563 B
Markdown

# src/io/platform_macos.rs
Shared macOS `fcntl(F_PREALLOCATE)` definitions.
The `libc` crate doesn't expose these symbols across all macOS SDK versions,
so we define them locally with values from `/usr/include/sys/fcntl.h`. Two
call sites ([`crate::io::writeback_file`] and `crate::io::sink::preallocate`)
need the same constants and `fstore_t` layout — keeping a single source of
truth here prevents the two copies from drifting.
Module-level cfg gate lives in the parent (`io/mod.rs`); this file is only
compiled on macOS, so no inner `#![cfg]` is needed.