1

I am looking deeply on the system function signal() and sigaction()

I read some pages on these two functions, and they mainly talked about the differences as portability and the "no - race condition".

Could anyone clarify these for me?

p.s. I was guided to use sigaction() function rather than signal() function when we are trying to change the control signals. Why is that?

Any help would be appreciated. Thank you guys!!

user2864740
  • 60,010
  • 15
  • 145
  • 220
Iankimm
  • 11
  • 1
  • Possible duplicate of [What is the difference between sigaction and signal?](http://stackoverflow.com/questions/231912/what-is-the-difference-between-sigaction-and-signal) – pilcrow Apr 19 '16 at 13:13

1 Answers1

0

sigaction() allows more control than signal(). Signal() was the original function used, but in order to be backward compatible when adding more features, a new name was chosen when wanting to set the new flags etc.

Stian Skjelstad
  • 2,277
  • 1
  • 9
  • 19