Changeset 25f7c57 for owl.c


Ignore:
Timestamp:
Mar 25, 2011, 3:55:41 AM (12 years ago)
Author:
David Benjamin <davidben@mit.edu>
Children:
ec9746d
Parents:
111850c
git-author:
David Benjamin <davidben@mit.edu> (03/03/11 09:50:32)
git-committer:
David Benjamin <davidben@mit.edu> (03/25/11 03:55:41)
Message:
Use sigwaitinfo instead of sigwait

Eh, may as well give the signal handlers a little bit more rope.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • owl.c

    r111850c r25f7c57  
    380380}
    381381
    382 static void sig_handler(int sig, void *data) {
     382static void sig_handler(const siginfo_t *siginfo, void *data) {
    383383  /* If it was an interrupt, set a flag so we can handle it earlier if
    384384   * needbe. sig_handler_main_thread will check the flag to make sure
    385385   * no one else took it. */
    386   if (sig == SIGINT) {
     386  if (siginfo->si_signo == SIGINT) {
    387387    owl_global_add_interrupt(&g);
    388388  }
    389389  /* Send a message to the main thread. */
    390   owl_select_post_task(sig_handler_main_thread, GINT_TO_POINTER(sig), NULL);
     390  owl_select_post_task(sig_handler_main_thread,
     391                       GINT_TO_POINTER(siginfo->si_signo), NULL);
    391392}
    392393
Note: See TracChangeset for help on using the changeset viewer.