>
> AFAIK, it's not possible to intercept SIGKILL.
>

    My mistake for the SIGKILL, it was actually SIGINT. But this is not my
point here. Sending either SIGTERM or SIGINT to a mono or mono embedded
process and handling it via sigaction is not acting like I want. I included
with this post an example.

    My goal here is to build something like a daemon, as for now, there is
no support for services in mono. If I get this thing to work, I'll look
closer at implementing this part. (There were some interesting posts here
with this concern, just wondering if someone is working on it)

    As for the example, a signal handler is registered as well as a managed
delegate method. The signal is handled fine, but the mono runtime seems to
handle it too... and this not what I want.

Compile with "make", run with "./sigtermtest" , kill with "killall
sigtermtest" and see what the termination looks like.

I'm not totally fluent with signals, so I may be missing something or I may
be running after something that is not possible with the mono runtime.

Any ideas ?

Jerome.

Attachment: sigtermtest.tar.bz2
Description: Binary data

Reply via email to