Signal handling.........
Hi all,
Generaly we use 'signal' or 'sigaction' for signal handler registration. But is there any way to unregister the signal handler. I mean to say taht suppose I have register my handler for SIGINI. Now I want to unregister the signal handler or disable my own signal handler. How can I do this ? Do any body has any idea ? Please help me in this regard. Thanking u all, With Regard, Rajesh. |
Hi rajsun,
With "signal" you can reset the handler for SIGINT to the system default with signal(SIGINT, SIG_DFL); With "sigaction" you can also use SIG_DFL, or you can supply the third argument to sigaction and save the previous handler and settings, to be restored later by another call to sigaction. See man 2 signal and man 2 sigaction They should give you a lot of info on the subject. ~sind |
Thank u sind. Thank u very much. Actully this concept didnt strick to my mind.
|
All times are GMT -5. The time now is 08:27 PM. |