HomeFreeBSD

Introduce nonnull attributes in the signal and pthread headers.

Description

Introduce nonnull attributes in the signal and pthread headers.

The `nonnull' attribute specifies that some function parameters should be
non-null pointers. This is very useful as it helps the compiler generate
warnings on suspicious code and can also enable some small optimizations.
In clang this is also useful for the static analyzer.

While we could go on defining this all over the tree, it only
makes sense to annotate a subset of critical functions.

Hinted by: Android's bionic libc
Differential Revision: https://reviews.freebsd.org/D2101

Details

Event Timeline