HomeFreeBSD

filedesc: cleanup setugidsafety a little

Description

filedesc: cleanup setugidsafety a little

Rename it to fdsetugidsafety for consistency with other functions.

There is no need to take filedesc lock if not closing any files.

The loop has to verify each file and we are guaranteed fdtable has space
for at least 20 fds. As such there is no need to check fd_lastfile.

While here tidy up is_unsafe.

Details

Provenance
mjgAuthored on
Parents
rS273440: Patch batch for 2014-10-22.
Branches
Unknown
Tags
Unknown

Event Timeline