[fpc-pascal] Stopping daemon in linux
JeLlyFish.software at gmx.net
Mon Nov 9 21:50:30 CET 2009
Jonas Maebe <jonas.maebe at elis.ugent.be>:
> On 09 Nov 2009, at 21:03, Michael Van Canneyt wrote:
> > On Mon, 9 Nov 2009, "Vinzent Höfler" wrote:
> >> As wrong as in "Don't call most system functions from within a
> >> signal handler.", maybe?
> > Hmm... In that case, many exceptions would not work either ?
> The sigaction handlers for catching exceptions have been fixed quite a
> while ago already to only collect the necessary information from the
> signal context, [...]
Additionally, signals causing run-time exceptions are triggered by the code itself, meaning things like SIGSEGV[*] are not actually "interrupting", rather they synchronously "transfer control" in a relatively well-defined way.
Maybe the analogy to good ol' DOS programming helps: Then signals are just interrupts, "synchronous" signals are "int xx" instructions, while "asynchronous" are real "hardware interrupts". Unfortunately you'll never know which will be which. ;)
[*] Of course, the SIGSEGV still could have been sent from another process making it interrupting and asynchronous like any other signal.
Jetzt kostenlos herunterladen: Internet Explorer 8 und Mozilla Firefox 3.5 -
sicherer, schneller und einfacher! http://portal.gmx.net/de/go/chbrowser
More information about the fpc-pascal