X-Git-Url: https://pintos-os.org/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=lib%2Ffatal-signal.c;h=2e38fc51aca1fc8b0e2c5d71f3fc8deff36a6abc;hb=3bcf3e33e9cfb7fd837086bfa8e627110d84dce8;hp=f6f913ebc0b1d2aa19923240344f40c88df37384;hpb=a0bc29a541fc7dc6e20137d5558e2094d614e6ab;p=openvswitch diff --git a/lib/fatal-signal.c b/lib/fatal-signal.c index f6f913eb..2e38fc51 100644 --- a/lib/fatal-signal.c +++ b/lib/fatal-signal.c @@ -134,6 +134,17 @@ fatal_signal_handler(int sig_nr) stored_sig_nr = sig_nr; } +/* Check whether a fatal signal has occurred and, if so, call the fatal signal + * hooks and exit. + * + * This function is called automatically by poll_block(), but specialized + * programs that may not always call poll_block() on a regular basis should + * also call it periodically. (Therefore, any function with "block" in its + * name should call fatal_signal_run() each time it is called, either directly + * or through poll_block(), because such functions can only used by specialized + * programs that can afford to block outside their main loop around + * poll_block().) + */ void fatal_signal_run(void) {