Re: [patch] netlink.7: srcfix Change buffer size in example code about reading netlink message.

2017-08-15 Thread Michael Kerrisk (man-pages)
On 11/14/2016 11:36 PM, Rick Jones wrote: >> Lets change the example so others don't propagate the problem further. >> >> Signed-off-by David Wilder >> >> --- man7/netlink.7.orig 2016-11-14 13:30:36.522101156 -0800 >> +++ man7/netlink.7 2016-11-14 13:30:51.002086354 -0800

Re: [patch] netlink.7: srcfix Change buffer size in example code about reading netlink message.

2017-08-15 Thread Michael Kerrisk (man-pages)
On 11/14/2016 11:20 PM, dwilder wrote: > The example code in netlink(7) (for reading netlink message) suggests > using > a 4k read buffer with recvmsg. This can cause truncated messages on > systems > using a page size is >4096. Please see: > linux/include/linux/netlink.h (in the kernel

Re: [patch] netlink.7: srcfix Change buffer size in example code about reading netlink message.

2016-11-14 Thread Rick Jones
Lets change the example so others don't propagate the problem further. Signed-off-by David Wilder --- man7/netlink.7.orig 2016-11-14 13:30:36.522101156 -0800 +++ man7/netlink.7 2016-11-14 13:30:51.002086354 -0800 @@ -511,7 +511,7 @@ .in +4n .nf int len; -char

[patch] netlink.7: srcfix Change buffer size in example code about reading netlink message.

2016-11-14 Thread dwilder
The example code in netlink(7) (for reading netlink message) suggests using a 4k read buffer with recvmsg. This can cause truncated messages on systems using a page size is >4096. Please see: linux/include/linux/netlink.h (in the kernel source) /* * skb should fit one page. This