summaryrefslogtreecommitdiffstats
path: root/lib/libthr
diff options
context:
space:
mode:
authorpeter <peter@FreeBSD.org>2008-12-07 02:32:49 +0000
committerpeter <peter@FreeBSD.org>2008-12-07 02:32:49 +0000
commitb14c2e0572eefde87a9f0cf31439b8a4c8b0dd1e (patch)
tree24ec6a1e099529415de6cce28a2cc94f628bcd9a /lib/libthr
parenteff63b34b11c4791d1aaa3cc5d59c42367c7ffaa (diff)
downloadFreeBSD-src-b14c2e0572eefde87a9f0cf31439b8a4c8b0dd1e.zip
FreeBSD-src-b14c2e0572eefde87a9f0cf31439b8a4c8b0dd1e.tar.gz
When libthr and rtld start up, there are a number of magic spells cast
in order to get the symbol binding state "just so". This is to allow locking to be activated and not run into recursion problems later. However, one of the magic bits involves an explicit call to _umtx_op() to force symbol resolution. It does a wakeup operation on a fake, uninitialized (ie: random contents) umtx. Since libthr isn't active, this is harmless. Nothing can match the random wakeup. However, valgrind finds this and is not amused. Normally I'd just write a suppression record for it, but the idea of passing random args to syscalls (on purpose) just doesn't feel right.
Diffstat (limited to 'lib/libthr')
-rw-r--r--lib/libthr/thread/thr_rtld.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/libthr/thread/thr_rtld.c b/lib/libthr/thread/thr_rtld.c
index 8e09494..bd64381 100644
--- a/lib/libthr/thread/thr_rtld.c
+++ b/lib/libthr/thread/thr_rtld.c
@@ -180,7 +180,7 @@ _thr_rtld_init(void)
{
struct RtldLockInfo li;
struct pthread *curthread;
- long dummy;
+ long dummy = -1;
curthread = _get_curthread();
OpenPOWER on IntegriCloud