Re: Calling system() in multi-threads.

2025-06-18 Thread Takashi Yano via Cygwin
On Tue, 17 Jun 2025 15:42:26 -0700 Mark Geisert wrote: > Hi Takashi, > > On 6/17/2025 5:54 AM, Takashi Yano via Cygwin wrote: > > Hi, > > > > If system() is called in parallel in threads, system() > > fails with exit code 127. > > > > Just compile pthread_system.c attached and run. > > > > I be

Re: Calling system() in multi-threads.

2025-06-17 Thread Mark Geisert via Cygwin
Hi Takashi, On 6/17/2025 5:54 AM, Takashi Yano via Cygwin wrote: Hi, If system() is called in parallel in threads, system() fails with exit code 127. Just compile pthread_system.c attached and run. I believe system() is multi-thread safe so the STC should work. I regret to inform that syste

Calling system() in multi-threads.

2025-06-17 Thread Takashi Yano via Cygwin
Hi, If system() is called in parallel in threads, system() fails with exit code 127. Just compile pthread_system.c attached and run. I believe system() is multi-thread safe so the STC should work. -- Takashi Yano #include #include #include #include #include void *func(void *arg) { prin