[mercury-users] problem with signals
Pieter Laeremans
pieter.laeremans at student.kuleuven.ac.be
Tue Mar 11 06:42:47 AEDT 2003
On Thu, 2003-03-06 at 15:04, Fergus Henderson wrote:
> one has an explanation for this ?
>
> By default, the Mercury compiler will invoke the C compiler with
> `-ansi', which will give you an ANSI/ISO C compliant set of standard
> header files. In standard ISO C, the <signal.h> header file does not
> provide sigemptyset() etc. If you want to make use of Posix extensions,
> such as sigemptyset() etc., you need to use the `--no-ansi-c' option to
> mmc and/or the `--no-ansi' option to mgnuc.
>
> This mess is needed because Posix chose to standardize the same header
> names as ANSI/ISO C, but with different contents.
Thx this fixes the compilation problem. However another problem
emerged. The sigprocmask I used to block for signals didn't had an
effect. I wondered why now I think I now.
ps -e showed me that therre were to processes of my mercury program.
Although I never spawn any thread somewhere. And signals are only
delivered to one thread.
Does the mercury runtime in someway spawns a new thread when a signal
gets delivered to program ?
Or does anyone have an idea how I can detect a which moment the second
thread emerges ?
thanks in advance,
Pieter
--------------------------------------------------------------------------
mercury-users mailing list
post: mercury-users at cs.mu.oz.au
administrative address: owner-mercury-users at cs.mu.oz.au
unsubscribe: Address: mercury-users-request at cs.mu.oz.au Message: unsubscribe
subscribe: Address: mercury-users-request at cs.mu.oz.au Message: subscribe
--------------------------------------------------------------------------
More information about the users
mailing list