On Sat, 2021-03-06 at 17:55 +0100, Marius Bakke wrote: > Hello Guilers, > > [...] > > It works great, except that the script filename (/tmp/test-shell) has > an open file descriptor which leaks into the new process: > > [...] > > I've managed to work around it by setting FD_CLOEXEC on it: > > [code using port-for-each and port-filename] > > But it seems heavy-handed. Is there an easier way to access the "script > port"? Perhaps Guile itself should make it FD_CLOEXEC by default? Easy way to access the ‘script port’: the Scheme procedure current-load-port. Take a look at the output of the attached script. Greetings, Maxime