A better implementation of the `execvp` call: the code implements `execvp`
The implementation is non-conformant.

No handling of undefined PATH. Quoting man execp:


search path is the path specified in the environment by
``PATH'' variable.  If this variable is not specified, the default path
is set according to the _PATH_DEFPATH definition in &lt;paths.h&gt;

Once confstr returns 0, check errno, and act accordingly.

Calling abort on execv failure is plain wrong. At least return what execv returns.

Calling access is also incorrect. If the file exists, but doesn't have correct permissions, execvp shall continue searching.


As a side note, access is very rarely useful. Consider calling execvp blindly, and testing errno upon return.

Final errno = ENOENT; is also non-compliant. execvp sets ENOENT if the file does not exist in any path. If it was found at least once, and fails to execute, the errno shall be EACCES.

execvp is not supposed to fprintf anything.