Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 12 Dec 2001 22:32:07 -0800
From:      Bill Huey <billh@gnuppy.monkey.org>
To:        Daniel Eischen <eischen@pcnet1.pcnet.com>
Cc:        Bill Huey <billh@gnuppy.monkey.org>, freebsd-java@FreeBSD.ORG
Subject:   Re: Pthreads bug fix [was Re: jdk1.3.1p5]
Message-ID:  <20011213063207.GA7359@gnuppy>
In-Reply-To: <Pine.SUN.3.91.1011212071002.11047A-100000@pcnet1.pcnet.com>
References:  <20011212074342.GB4677@gnuppy> <Pine.SUN.3.91.1011212071002.11047A-100000@pcnet1.pcnet.com>

next in thread | previous in thread | raw e-mail | index | archive | help
On Wed, Dec 12, 2001 at 07:24:12AM -0500, Daniel Eischen wrote:
> > > diff -u -r1.38 uthread_kern.c
> > > --- uthread_kern.c	4 May 2001 20:37:07 -0000	1.38
> > > +++ uthread_kern.c	12 Dec 2001 04:15:35 -0000
> > > @@ -387,6 +387,10 @@
> > >  		    ((pthread->wakeup_time.tv_sec == ts.tv_sec) &&
> > >  		    (pthread->wakeup_time.tv_nsec <= ts.tv_nsec)))) {
> > >  			switch (pthread->state) {
> > > +			case PS_SUSPENDED:
> > > +				PTHREAD_WAITQ_REMOVE(pthread);
> > > +				pthread->suspended = SUSP_YES;
> > > +				break;
> > >  			case PS_POLL_WAIT:
> > >  			case PS_SELECT_WAIT:
> > >  				/* Return zero file descriptors ready: */
> > > Dan Eischen
> 
> Yes, this should keep the state equal to PS_SUSPENDED.  When the thread
> is resumed, its state should be set to PS_RUNNING and then it will be
> added back to the run queue.

This didn't work. A thread would SEGV and then the entire thing blows up
shortly afterward in a wierd kind of delayed signal delivery way.

bill


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-java" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20011213063207.GA7359>