Re: [fpc-pascal] Problem with file descriptors when doing fork on linux

2018-02-02 Thread Luca Olivetti
El 02/02/18 a les 11:33, Michael Van Canneyt ha escrit: Or more generally do exists in fpc some other way how to deal with this problem - to create new process but without copied file descriptors? No, currently not. Why doesn't the unix implementation take into account the

Re: [fpc-pascal] Problem with file descriptors when doing fork on linux

2018-02-02 Thread Michael Van Canneyt
On Fri, 2 Feb 2018, Ko Paka wrote: Hello, I would like to ask advice. My colleague run into a problem, when he had used TProcess to spawn other process. Because of fork nature, file descriptors was copied into newly created process. He found that for such cases CLOEXEC flag exists to be used

[fpc-pascal] Problem with file descriptors when doing fork on linux

2018-02-02 Thread Ko Paka
Hello, I would like to ask advice. My colleague run into a problem, when he had used TProcess to spawn other process. Because of fork nature, file descriptors was copied into newly created process. He found that for such cases CLOEXEC flag exists to be used when open file. I found flag declared