Re: posix_spawn (was: Bugs with execline/s6 documentation and skalibs functions using posix_spawn())

From: Casper Ti. Vector <caspervector_at_gmail.com>
Date: Thu, 29 Jun 2023 22:16:26 +0800

On Thu, Jun 29, 2023 at 11:04:33AM +0000, Laurent Bercot wrote:
> Indeed, /dev should work; but using it still makes me queasier than
> crafting a nonexistent path.

Actually deliberately supplying a directory to posix_spawn*() is
a slightly deeper test, as the path exists but is unexecutable.
But surely this does not constitute a decisive advantage.

> Of course, it doesn't matter for glibc, and it doesn't matter for
> s6 which needs fork anyway. And chances are that platforms that
> implement posix_spawn() with internals that are *not* fork+exec will
> not make it return before the spawning has really succeeded. But still,
> it's nice to make sure it can be used wherever it exists.

Now I see, thanks...

> If you don't like the workaround, nobody's preventing you from using
> --with-sysdep-posixspawn=no manually. ;)

Yes, and I am keeping my origin solution at work intact :)

-- 
My current OpenPGP key:
RSA4096/0x227E8CAAB7AA186C (expires: 2024.09.30)
7077 7781 B859 5166 AE07 0286 227E 8CAA B7AA 186C
Received on Thu Jun 29 2023 - 16:16:26 CEST

This archive was generated by hypermail 2.4.0 : Thu Jun 29 2023 - 16:17:01 CEST