Follow @Openwall on Twitter for new release announcements and other news
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Date: Wed, 12 Aug 2015 16:18:58 +0200
From: Jens Gustedt <jens.gustedt@...ia.fr>
To: musl@...ts.openwall.com
Subject: Re: Thread hangs up when calling exit()

Hello,

Am Mittwoch, den 12.08.2015, 10:04 -0400 schrieb Rich Felker:
> On Wed, Aug 12, 2015 at 04:36:20PM +0300, Eugene wrote:
> > Hello,
> > 
> > I have problem with threads.
> > Main thread waits for input through function fgets().
> > Other thread calls function exit() and hangs up.
> > Main thread continues working.
> > ...
> As far as I can tell this is the required behavior specified by POSIX.
> I raised a related issue with the standards body in 2012 and the
> effects on exit were deemed intentional. See:
> 
> http://austingroupbugs.net/view.php?id=611

yes, this behavior also seems to be in line with C11 threads and
io.

If you want to exit (and not abort) under such circumstances you could
use the C11 function quick_exit, which musl implements.

Jens

-- 
:: INRIA Nancy Grand Est ::: Camus ::::::: ICube/ICPS :::
:: ::::::::::::::: office Strasbourg : +33 368854536   ::
:: :::::::::::::::::::::: gsm France : +33 651400183   ::
:: ::::::::::::::: gsm international : +49 15737185122 ::
:: http://icube-icps.unistra.fr/index.php/Jens_Gustedt ::




Download attachment "signature.asc" of type "application/pgp-signature" (182 bytes)

Powered by blists - more mailing lists

Confused about mailing lists and their use? Read about mailing lists on Wikipedia and check out these guidelines on proper formatting of your messages.