Re: [PATCH] RDMA/nldev: add check for null return from call to nlmsg_put

2019-05-16 Thread Leon Romanovsky
On Thu, May 16, 2019 at 02:12:15PM +0100, Colin King wrote: > From: Colin Ian King > > It is possible that nlmsg_put can return a null pointer, currently > this will lead to a null pointer dereference when passing a null > nlh pointer to nlmsg_end. Fix this by adding a null pointer check. > > Add

[PATCH] RDMA/nldev: add check for null return from call to nlmsg_put

2019-05-16 Thread Colin King
From: Colin Ian King It is possible that nlmsg_put can return a null pointer, currently this will lead to a null pointer dereference when passing a null nlh pointer to nlmsg_end. Fix this by adding a null pointer check. Addresses-Coverity: ("Dereference null return value") Fixes: cb7e0e130503 (