summaryrefslogtreecommitdiff
path: root/nptl/sysdeps/unix/sysv/linux/fork.c
diff options
context:
space:
mode:
authorJakub Jelinek <jakub@redhat.com>2008-10-20 07:21:57 +0000
committerJakub Jelinek <jakub@redhat.com>2008-10-20 07:21:57 +0000
commit6d8225fe1a3277273c245ceb1b35fd536300f649 (patch)
tree2c0992e862046504ff1767f29601e35981ca4d47 /nptl/sysdeps/unix/sysv/linux/fork.c
parent315a43aa949b25896c511fa6e2efd6be57e2e01d (diff)
Updated to fedora-glibc-20081019T1815cvs/fedora-glibc-2_8_90-14
Diffstat (limited to 'nptl/sysdeps/unix/sysv/linux/fork.c')
-rw-r--r--nptl/sysdeps/unix/sysv/linux/fork.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/nptl/sysdeps/unix/sysv/linux/fork.c b/nptl/sysdeps/unix/sysv/linux/fork.c
index 1683de80fd..524d72c587 100644
--- a/nptl/sysdeps/unix/sysv/linux/fork.c
+++ b/nptl/sysdeps/unix/sysv/linux/fork.c
@@ -1,4 +1,4 @@
-/* Copyright (C) 2002, 2003, 2007 Free Software Foundation, Inc.
+/* Copyright (C) 2002, 2003, 2007, 2008 Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by Ulrich Drepper <drepper@redhat.com>, 2002.
@@ -64,6 +64,9 @@ __libc_fork (void)
struct fork_handler *runp;
while ((runp = __fork_handlers) != NULL)
{
+ /* Make sure we read from the current RUNP pointer. */
+ atomic_full_barrier ();
+
unsigned int oldval = runp->refcntr;
if (oldval == 0)