Re: [PATCH iproute2-next] libnetlink: Use NLMSG_LENGTH to set nlmsg_len

2018-10-05 Thread David Ahern
On 10/4/18 3:37 PM, David Ahern wrote: > From: David Ahern > > Some of the inner headers are not 4-byte aligned, so use > NLMSG_LENGTH instead of sizeof(req) to set nlmsg_len. > this patch is wrong; headers are supposed to be 4-bytes aligned.

[PATCH iproute2-next] libnetlink: Use NLMSG_LENGTH to set nlmsg_len

2018-10-04 Thread David Ahern
From: David Ahern Some of the inner headers are not 4-byte aligned, so use NLMSG_LENGTH instead of sizeof(req) to set nlmsg_len. Signed-off-by: David Ahern --- lib/libnetlink.c | 16 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/lib/libnetlink.c b/lib/libnetlin