Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/share/man/man4 Correct the example in kcov(4)
details: https://anonhg.NetBSD.org/src/rev/9b55b14883ee
branches: trunk
changeset: 999318:9b55b14883ee
user: kamil <kamil%NetBSD.org@localhost>
date: Tue May 28 21:31:53 2019 +0000
description:
Correct the example in kcov(4)
mmap(2) has to be called with MAP_SHARED, not MAP_PRIVATE.
Reported by Maciej Grochowski.
diffstat:
share/man/man4/kcov.4 | 6 +++---
1 files changed, 3 insertions(+), 3 deletions(-)
diffs (27 lines):
diff -r 039c4529f4c0 -r 9b55b14883ee share/man/man4/kcov.4
--- a/share/man/man4/kcov.4 Tue May 28 20:22:18 2019 +0000
+++ b/share/man/man4/kcov.4 Tue May 28 21:31:53 2019 +0000
@@ -1,4 +1,4 @@
-.\" $NetBSD: kcov.4,v 1.5 2019/05/26 01:44:34 kamil Exp $
+.\" $NetBSD: kcov.4,v 1.6 2019/05/28 21:31:53 kamil Exp $
.\"
.\" Copyright (c) 2018 Anton Lindqvist <anton%openbsd.org@localhost>
.\"
@@ -14,7 +14,7 @@
.\" ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
.\" OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
.\"
-.Dd May 26, 2019
+.Dd May 28, 2019
.Dt KCOV 4
.Os
.Sh NAME
@@ -165,7 +165,7 @@
if (ioctl(fd, KCOV_IOC_SETBUFSIZE, &size) == -1)
err(1, "ioctl: KCOV_IOC_SETBUFSIZE");
cover = mmap(NULL, size * KCOV_ENTRY_SIZE,
- PROT_READ | PROT_WRITE, MAP_PRIVATE, fd, 0);
+ PROT_READ | PROT_WRITE, MAP_SHARED, fd, 0);
if (cover == MAP_FAILED)
err(1, "mmap");
mode = KCOV_MODE_TRACE_PC;
Home |
Main Index |
Thread Index |
Old Index