any one has knowladge in C unix opreating system please hel
any one has knowladge in C unix opreating system .. please help
Describe how to use sigaction such that a process can send a payload with the signal that can be retrieved by the receiving process.Solution
Signals are intented for passing an excessive data between processes. Consider another IPC mechanism like pipes, sockets etc.
Or Alternatively you can use them in conjuction. Eg, share 2 ends of pipe between processes, then write something to it in process A , then send signal to process B. Delivering of a signal to process B is treated as readiness to tead from a pipe, then process B just reads data from a pipe, that were written by A.
When installing sigaction() use SA_SIFINFO() so that the signature of handler is
void signal_handler(int signum, siginfo_t *info, void *context), context is a pointer or an int stored in an union of type union sigval.
