Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 29 Aug 2008 23:30:04 GMT
From:      agile@sunbay.com
To:        freebsd-threads@FreeBSD.org
Subject:   Re: threads/126950: rtld malloc is thread-unsafe
Message-ID:  <200808292330.m7TNU4Yu027171@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help
The following reply was made to PR threads/126950; it has been noted by GNATS.

From: agile@sunbay.com
To: "Alexander Kabaev" <kabaev@gmail.com>
Cc: bug-followup@FreeBSD.org
Subject: Re: threads/126950: rtld malloc is thread-unsafe
Date: Sat, 30 Aug 2008 02:00:10 +0300 (EEST)

 Thx for hint, Alexander. There only two functions, that called without
 bind lock:
 
 objlist_call_init,
 objlist_call_fini,
 
 they both use
 
 errmsg_save (which call xstrdup)
 errmsg_restore (which call free)
 
 Need to move them under exclusive bind lock protection.
 
 > 1. The locking implementation in this patch is broken.
 > 2. rtld malloc is not supposed to be called from multiple threads and
 > needs to be protected by exclusive bind lock. If there are code
 > sections that call malloc without exclusive lock held, rtld
 > should be fixed to move them under lock protection.
 >
 > --
 > Alexander Kabaev
 >
 
 



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