Subject: re: kern/32962
To: None <gnats-bugs@netbsd.org, netbsd-bugs@netbsd.org>
From: matthew green <mrg@eterna.com.au>
List: netbsd-bugs
Date: 10/17/2006 19:22:09
this patch seems to fix this problem for me.


.mrg.


Index: kern_sig.c
===================================================================
RCS file: /cvsroot/src/sys/kern/kern_sig.c,v
retrieving revision 1.230
diff -p -r1.230 kern_sig.c
*** kern_sig.c	12 Oct 2006 01:32:17 -0000	1.230
--- kern_sig.c	17 Oct 2006 07:06:07 -0000
*************** kpsignal2(struct proc *p, const ksiginfo
*** 1354,1382 ****
  	/*NOTREACHED*/
  
   runfast:
- 	if (action == SIG_CATCH) {
- 		ksiginfo_put(p, ksi);
- 		action = SIG_HOLD;
- 	}
  	/*
  	 * Raise priority to at least PUSER.
  	 */
  	if (l->l_priority > PUSER)
  		l->l_priority = PUSER;
   run:
- 	if (action == SIG_CATCH) {
- 		ksiginfo_put(p, ksi);
- 		action = SIG_HOLD;
- 	}
- 
  	setrunnable(l);		/* XXXSMP: recurse? */
   out:
- 	if (action == SIG_CATCH)
- 		ksiginfo_put(p, ksi);
   done:
  	/* XXXSMP: works, but icky */
  	if (dolock)
  		SCHED_UNLOCK(s);
  }
  
  siginfo_t *
--- 1354,1373 ----
  	/*NOTREACHED*/
  
   runfast:
  	/*
  	 * Raise priority to at least PUSER.
  	 */
  	if (l->l_priority > PUSER)
  		l->l_priority = PUSER;
   run:
  	setrunnable(l);		/* XXXSMP: recurse? */
   out:
   done:
  	/* XXXSMP: works, but icky */
  	if (dolock)
  		SCHED_UNLOCK(s);
+ 	if (action == SIG_CATCH)
+ 		ksiginfo_put(p, ksi);
  }
  
  siginfo_t *