diff options
author | 2003-12-08 22:44:18 +0000 | |
---|---|---|
committer | 2003-12-08 22:44:18 +0000 | |
commit | 4faf53bb8287686f3cd971118e16e4d3f66366d5 (patch) | |
tree | e9cfabfbe2824611eb9fecc20658e49c98cd0b73 /usr.bin/patch/inp.c | |
parent | remove unneeded uvmfault_unlockmaps; form netbsd via Julien Bordet <zejames@greyhats.org>; tedu@ ok (diff) | |
download | wireguard-openbsd-4faf53bb8287686f3cd971118e16e4d3f66366d5.tar.xz wireguard-openbsd-4faf53bb8287686f3cd971118e16e4d3f66366d5.zip |
MAP_FILE is the default and MAP_PRIVATE has to be given or produces evil warnings in debug kernel
Diffstat (limited to 'usr.bin/patch/inp.c')
-rw-r--r-- | usr.bin/patch/inp.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/usr.bin/patch/inp.c b/usr.bin/patch/inp.c index 156848dea91..3326843ad00 100644 --- a/usr.bin/patch/inp.c +++ b/usr.bin/patch/inp.c @@ -1,4 +1,4 @@ -/* $OpenBSD: inp.c,v 1.30 2003/11/21 21:25:59 mickey Exp $ */ +/* $OpenBSD: inp.c,v 1.31 2003/12/08 22:44:18 mickey Exp $ */ /* * patch - a program to apply diffs to original files @@ -27,7 +27,7 @@ */ #ifndef lint -static const char rcsid[] = "$OpenBSD: inp.c,v 1.30 2003/11/21 21:25:59 mickey Exp $"; +static const char rcsid[] = "$OpenBSD: inp.c,v 1.31 2003/12/08 22:44:18 mickey Exp $"; #endif /* not lint */ #include <sys/types.h> @@ -248,7 +248,7 @@ plan_a(const char *filename) if ((ifd = open(filename, O_RDONLY)) < 0) pfatal("can't open file %s", filename); - i_womp = mmap(NULL, i_size, PROT_READ, MAP_FILE, ifd, 0); + i_womp = mmap(NULL, i_size, PROT_READ, MAP_PRIVATE, ifd, 0); if (i_womp == MAP_FAILED) { perror("mmap failed"); i_womp = NULL; |