You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
* Cast pointers more carefully
Prefer ptr::{cast, cast_const, cast_mut} over `as`. The latter makes it
too easy to accidentally change both the type and mutability when
changing only one was intended.
This exercise caught an unintended mutability cast in one function, the
BSD version of sendfile. In this case there's no UB because it isn't
possible for anything else to get a reference to the data that was
incorrectly cast.
There was also a type cast that wasn't guaranteed to be correct (but
probably was) due to memory layout guarantees in if_nametoindex.
* Remove unnecessary cast in UnixCredentials::groups
0 commit comments