HomeFreeBSD

MFC r264737:

Description

MFC r264737:

Discussed with: jilles

r264737 (by jilles):

libc/stdio: Fail fdopen() on an execute-only fd.

An execute-only fd (opened with O_EXEC) allows neither read() nor write()
and is therefore incompatible with all stdio modes. Therefore, the [EINVAL]
error applies.

Also adjust the similar check in freopen() with a NULL path, even though
this checks an fd which is already from a FILE.

Details

Provenance
ngieAuthored on
Parents
rS291292: Overhaul if_enc(4) and make it loadable in run-time.
Branches
Unknown
Tags
Unknown