Version française
Home     About     Download     Resources     Contact us    

This site is updated infrequently. For up-to-date information, please visit the new OCaml website at

Browse thread
[Caml-list] OS X: Trouble with threads + execv
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: -- (:)
From: Nathaniel Gray <n8gray@c...>
Subject: Re: [Caml-list] OS X: Trouble with threads + execv
On Jul 8, 2004, at 8:09 AM, Xavier Leroy wrote:

>> I'm seeing some confusing behavior on OS X (10.3.4) relating to
>> pthreads and the execv family of calls.  It appears that when the
>> scheduler thread (from otherlibs/systhreads/ is
>> running, any call to execv will fail with "Operation not supported."
>> The same applies to execvp, execve, and execvpe.
>> If I build the program without linking to threads.cmxa then it works 
>> as
>> expected.
>> Is this expected behavior?
> No.  According to POSIX, exec* has no reason to fail if other threads
> are still running in the current process.  These other threads are
> terminated.  With system threads, Caml's Unix.exec* functions just
> call the corresponding system calls.
> If you want to make sure, you could try to reproduce this behavior
> with a small C program.

Thanks.  I was able to reproduce it with a C program so I'll file a bug 
report with Apple.


 >>>-- Nathaniel Gray -- Caltech Computer Science ------>
 >>>-- Mojave Project -- -->

To unsubscribe, mail Archives:
Bug reports: FAQ:
Beginner's list: