summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorHans Dedecker <dedeckeh@gmail.com>2018-05-26 13:30:47 +0200
committerHans Dedecker <dedeckeh@gmail.com>2018-05-26 13:32:02 +0200
commit12e21bca86882298f74d3603e909449afc86df79 (patch)
treef1ec3ab04316d5c59a8c1c5f09375141d582c845
parentd7aa414e47da1ab41df8b07307087c0e91b4ffa9 (diff)
netlink: fix incorrect sizeof argument
Fix incorrect sizeof arguments detetced by Coverity in CID 1430866 and CID 1430893 Signed-off-by: Hans Dedecker <dedeckeh@gmail.com>
-rw-r--r--src/netlink.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/netlink.c b/src/netlink.c
index e9fd04a..56d35df 100644
--- a/src/netlink.c
+++ b/src/netlink.c
@@ -234,14 +234,14 @@ static int cb_rtnl_valid(struct nl_msg *msg, _unused void *arg)
event_info.rt.dst_len = rtm->rtm_dst_len;
if (nla[RTA_DST])
nla_memcpy(&event_info.rt.dst, nla[RTA_DST],
- sizeof(&event_info.rt.dst));
+ sizeof(event_info.rt.dst));
if (nla[RTA_OIF])
event_info.iface = odhcpd_get_interface_by_index(nla_get_u32(nla[RTA_OIF]));
if (nla[RTA_GATEWAY])
nla_memcpy(&event_info.rt.gateway, nla[RTA_GATEWAY],
- sizeof(&event_info.rt.gateway));
+ sizeof(event_info.rt.gateway));
call_netevent_handler_list(add ? NETEV_ROUTE6_ADD : NETEV_ROUTE6_DEL,
&event_info);