Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/lib/librumpuser Apparently MAP_ANON mmap() on Linux requires...
details: https://anonhg.NetBSD.org/src/rev/fd191962caf6
branches: trunk
changeset: 783284:fd191962caf6
user: pooka <pooka%NetBSD.org@localhost>
date: Thu Dec 13 15:35:09 2012 +0000
description:
Apparently MAP_ANON mmap() on Linux requires MAP_PRIVATE to be specified
for the addr parameter to have a sane effect. Make it so.
diffstat:
lib/librumpuser/rumpuser.c | 6 +++---
1 files changed, 3 insertions(+), 3 deletions(-)
diffs (27 lines):
diff -r 4f5151c7e7f6 -r fd191962caf6 lib/librumpuser/rumpuser.c
--- a/lib/librumpuser/rumpuser.c Thu Dec 13 15:16:57 2012 +0000
+++ b/lib/librumpuser/rumpuser.c Thu Dec 13 15:35:09 2012 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: rumpuser.c,v 1.23 2012/11/18 19:29:40 pooka Exp $ */
+/* $NetBSD: rumpuser.c,v 1.24 2012/12/13 15:35:09 pooka Exp $ */
/*
* Copyright (c) 2007-2010 Antti Kantee. All Rights Reserved.
@@ -28,7 +28,7 @@
#include "rumpuser_port.h"
#if !defined(lint)
-__RCSID("$NetBSD: rumpuser.c,v 1.23 2012/11/18 19:29:40 pooka Exp $");
+__RCSID("$NetBSD: rumpuser.c,v 1.24 2012/12/13 15:35:09 pooka Exp $");
#endif /* !lint */
#include <sys/ioctl.h>
@@ -261,7 +261,7 @@
if (exec)
prot |= PROT_EXEC;
rv = mmap(prefaddr, size, prot,
- MAP_ANON | MAP_ALIGNED(alignbit), -1, 0);
+ MAP_PRIVATE | MAP_ANON | MAP_ALIGNED(alignbit), -1, 0);
if (rv == MAP_FAILED) {
seterror(errno);
return NULL;
Home |
Main Index |
Thread Index |
Old Index