From 224a0025ee8f94ee90f64a8e67a9bd4510f60a8d Mon Sep 17 00:00:00 2001 From: Michael Kerrisk Date: Wed, 16 Aug 2017 02:39:07 +0200 Subject: [PATCH] netlink.7: Add a comment on 8192 buffer size in example code Reported-by: Rick Jones Signed-off-by: Michael Kerrisk --- man7/netlink.7 | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/man7/netlink.7 b/man7/netlink.7 index 9993a5c96..a13987cac 100644 --- a/man7/netlink.7 +++ b/man7/netlink.7 @@ -533,7 +533,8 @@ And the last example is about reading netlink message. .in +4n .nf int len; -char buf[8192]; +char buf[8192]; /* 8192 to avoid message truncation on + platforms with page size > 4096 */ struct iovec iov = { buf, sizeof(buf) }; struct sockaddr_nl sa; struct msghdr msg;