From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.org/gmane.linux.lib.musl.general/11088 Path: news.gmane.org!.POSTED!not-for-mail From: Rich Felker Newsgroups: gmane.linux.lib.musl.general Subject: Re: ldso pthread finalization Date: Sun, 26 Feb 2017 16:33:12 -0500 Message-ID: <20170226213312.GA1520@brightrain.aerifal.cx> References: Reply-To: musl@lists.openwall.com NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Trace: blaine.gmane.org 1488144814 29369 195.159.176.226 (26 Feb 2017 21:33:34 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Sun, 26 Feb 2017 21:33:34 +0000 (UTC) User-Agent: Mutt/1.5.21 (2010-09-15) To: musl@lists.openwall.com Original-X-From: musl-return-11103-gllmg-musl=m.gmane.org@lists.openwall.com Sun Feb 26 22:33:28 2017 Return-path: Envelope-to: gllmg-musl@m.gmane.org Original-Received: from mother.openwall.net ([195.42.179.200]) by blaine.gmane.org with smtp (Exim 4.84_2) (envelope-from ) id 1ci6RY-0006mj-5t for gllmg-musl@m.gmane.org; Sun, 26 Feb 2017 22:33:24 +0100 Original-Received: (qmail 24232 invoked by uid 550); 26 Feb 2017 21:33:27 -0000 Mailing-List: contact musl-help@lists.openwall.com; run by ezmlm Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-ID: Original-Received: (qmail 24214 invoked from network); 26 Feb 2017 21:33:26 -0000 Content-Disposition: inline In-Reply-To: Original-Sender: Rich Felker Xref: news.gmane.org gmane.linux.lib.musl.general:11088 Archived-At: On Sun, Feb 26, 2017 at 12:48:07PM +0300, Леонид Юрьев wrote: > Hi, > > In glibc there are a couple of problems. I do not know whether they > are relevant for Musl. However, I think should pay attention. > > So, please take in accound two glibc bugs: > > 1) pthread_key_delete() race with thread finalization. > > A race condition could occur between the pthread_key_delete() and the > __nptl_deallocate_tsd(). I consider deletion of a key for which a value is set to be a type of use-after-free bug and thereby to have undefined behavior. POSIX does not seem to specify a behavior for it, and it does not seem possible to specify something consistent. > 2) pthread_key_create() destructors and segfault after a DSO unloading. musl does not unload DSOs, so this one is not relevant to musl. Rich