8002ddd167174f30108d9b3b81cf80578b54609b
Fixes a minor race condition in active_displays that might happen if a display is removed between the active_display_count and the CGGetActiveDisplayList. In that case the returned vec would be inconsistent and contain one (or more) spurious null displays. Note: the returned value will always be subject to TOC/TOU, of course, but this specific case has the returned value containing invalid displays with id=0 that were never supposed to be in the returned value in any possible state of the displays; this commit fixes this case.
core-foundation-rs
Compatibility
Targets macOS 10.7 by default.
To enable features added in macOS 10.8, set Cargo feature mac_os_10_8_features. To have both 10.8 features and 10.7 compatibility, also set mac_os_10_7_support. Setting both requires weak linkage, which is a nightly-only feature as of Rust 1.19.
For more experimental but more complete, generated bindings take a look at https://github.com/michaelwu/RustKit. Other alternatives are https://github.com/nvzqz/fruity and https://gitlab.com/objrs/objrs
Contributing
If you wish to start contributing or even make a one-off change, simply submit a pull request with the code or documentation change and we'll go from there.
Description
Languages
Rust
100%