[BACK]Return to kern_sig.c CVS log [TXT][DIR] Up to [cvs.NetBSD.org] / src / sys / kern

Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.

Diff for /src/sys/kern/kern_sig.c between version 1.347 and 1.348

version 1.347, 2018/05/20 04:00:35 version 1.348, 2018/05/28 13:12:54
Line 904  trapsignal(struct lwp *l, ksiginfo_t *ks
Line 904  trapsignal(struct lwp *l, ksiginfo_t *ks
         KASSERT(!cpu_intr_p());          KASSERT(!cpu_intr_p());
         mutex_enter(proc_lock);          mutex_enter(proc_lock);
         mutex_enter(p->p_lock);          mutex_enter(p->p_lock);
   
           if (ISSET(p->p_slflag, PSL_TRACED) && (p->p_pptr != p->p_opptr)) {
                   p->p_xsig = signo;
                   p->p_sigctx.ps_faked = true; // XXX
                   p->p_sigctx.ps_info._signo = signo;
                   p->p_sigctx.ps_info._code = ksi->ksi_code;
                   sigswitch(0, signo, false);
                   // XXX ktrpoint(KTR_PSIG)
                   mutex_exit(p->p_lock);
                   return;
           }
   
         mask = &l->l_sigmask;          mask = &l->l_sigmask;
         ps = p->p_sigacts;          ps = p->p_sigacts;
   
         const bool traced = (p->p_slflag & PSL_TRACED) != 0;  
         const bool caught = sigismember(&p->p_sigctx.ps_sigcatch, signo);          const bool caught = sigismember(&p->p_sigctx.ps_sigcatch, signo);
         const bool masked = sigismember(mask, signo);          const bool masked = sigismember(mask, signo);
         if (!traced && caught && !masked) {          if (caught && !masked) {
                 mutex_exit(proc_lock);                  mutex_exit(proc_lock);
                 l->l_ru.ru_nsignals++;                  l->l_ru.ru_nsignals++;
                 kpsendsig(l, ksi, mask);                  kpsendsig(l, ksi, mask);

Legend:
Removed from v.1.347  
changed lines
  Added in v.1.348

CVSweb <webmaster@jp.NetBSD.org>