diff options
Diffstat (limited to 'lib/librthread/rthread_stack.c')
-rw-r--r-- | lib/librthread/rthread_stack.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/lib/librthread/rthread_stack.c b/lib/librthread/rthread_stack.c index 7b178a4fa78..f73178ff35f 100644 --- a/lib/librthread/rthread_stack.c +++ b/lib/librthread/rthread_stack.c @@ -1,4 +1,4 @@ -/* $OpenBSD: rthread_stack.c,v 1.11 2013/12/18 16:42:08 deraadt Exp $ */ +/* $OpenBSD: rthread_stack.c,v 1.12 2014/06/27 23:21:47 matthew Exp $ */ /* $snafu: rthread_stack.c,v 1.12 2005/01/11 02:45:28 marc Exp $ */ /* PUBLIC DOMAIN: No Rights Reserved. Marco S Hyman <marc@snafu.org> */ @@ -92,7 +92,8 @@ _rthread_alloc_stack(pthread_t thread) size += guardsize; /* actually allocate the real stack */ - base = mmap(NULL, size, PROT_READ | PROT_WRITE, MAP_ANON, -1, 0); + base = mmap(NULL, size, PROT_READ | PROT_WRITE, + MAP_PRIVATE | MAP_ANON, -1, 0); if (base == MAP_FAILED) { free(stack); return (NULL); |