fexecve(2): Return ENOENT if exec a script opened with O_CLOEXEC
If a script (i.e., interpreter file) is opened with the O_CLOEXEC flag,
it would be closed by the time the interpreter is executed, and then the
executation would fail. So just return ENOENT from fexecve(2). This
behavior aligns with Linux's.
See Linux's fexecve(2) man page.
See also: https://bugzilla.kernel.org/show_bug.cgi?id=74481
Thank dillon for implementing the holdvnode2() function to obtain the
fileflags together with the fp from fd.