Re: Signal handlers - please help to understand



Igor Gorbounov wrote:
I need a help in understanding this thing: what is actually done when somewhere in a program some signal is emitted?

A widget calls g_signal_emit() with parameters to be passed to the
signal handler. Any code that registered to receive that signal gets
called in gsignal.c with g_closure_invoke().

Where are data originated from? Does
it all behave as a calling procedure and is stack used here? Well, here is a situation: some data come into commport, my app receives a SIGIO signal and emits a custom signal (from a sigc++ library), that delivers the receved data to other parts of a program. So what is going here - is this SIGIO signal handler participating in further data propagation or it looks like this handler just raised some flag and exited? Is there any "halvanic" connection between the SIGIO handler and the parts of program, that use those data? Where do those data belong?
Or, what is their scope?



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]