Blocking signals to a process
Web Server forum
Back To The Forum Home!Search!Private Messaging System

Web Server Talk Web Server Talk > Unix and Linux reviews > Free Unix support > Unix Programming > Blocking signals to a process




  Last Thread   Next Thread Next
  Show Printable Version Email this Page Subscribe to this Thread      Post New Thread    Post A Reply      

    Blocking signals to a process  
Rafael Almeida


View Ip Address Report This Message To A Moderator Edit/Delete Message


 
06-24-07 12:22 PM

Hello,

I'd like to know if there's some way of blocking signals to a certain
process. Even if it sets a handler with signal or sigaction I want the
signal to never arrive to the process. Is there any way of doing that?

I noticed that if I block the signal and then fork a child process, if
the child sets a signal handler, then it's able to get the signals. In
particular, I want to block SIGALRM to ever reaching some process.

I'm using linux, so linux-specific solutions are ok.





[ Post a follow-up to this message ]



    Re: Blocking signals to a process  
phil-news-nospam@ipal.net


View Ip Address Report This Message To A Moderator Edit/Delete Message


 
06-24-07 12:22 PM

On Sun, 24 Jun 2007 03:30:12 -0300 Rafael Almeida <rafaelc@dcc.ufmg.br> wrot
e:
| Hello,
|
| I'd like to know if there's some way of blocking signals to a certain
| process. Even if it sets a handler with signal or sigaction I want the
| signal to never arrive to the process. Is there any way of doing that?
|
| I noticed that if I block the signal and then fork a child process, if
| the child sets a signal handler, then it's able to get the signals. In
| particular, I want to block SIGALRM to ever reaching some process.
|
| I'm using linux, so linux-specific solutions are ok.

You can do it from within the process:

man sigsetmask


If you want to do it from outside the process:

man ptrace

--
|---------------------------------------/----------------------------------|
| Phil Howard KA9WGN (ka9wgn.ham.org)  /  Do not send to the address below |
| first name lower case at ipal.net   /  spamtrap-2007-06-24-0717@ipal.net |
|------------------------------------/-------------------------------------|





[ Post a follow-up to this message ]



    Sponsored Links  




 





   All times are GMT. The time now is 07:51 PM.      Post New Thread    Post A Reply      
  Last Thread   Next Thread Next


Most Popular forums 

Forum Jump:
Rate This Thread:

Forum Rules:
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is OFF
vB code is ON
Smilies are ON
[IMG] code is OFF
 
Medical and Health forum | Computer Games Reviews | Graphics design forum

Back To The Top
Home | Usercp | Faq | Register