From 21adfd2ba4324bb8575b17ecd76c0f3b3988246e Mon Sep 17 00:00:00 2001 From: Tobias Klauser Date: Sun, 12 May 2013 12:17:15 +0200 Subject: flowtop: Use size of destination buffer in memcpy The coverity scanner found the macro used as argument to sizeof suspicious. Use sizeof the destination buffer instead. Signed-off-by: Tobias Klauser --- flowtop.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/flowtop.c b/flowtop.c index e67859c..43d770e 100644 --- a/flowtop.c +++ b/flowtop.c @@ -577,7 +577,7 @@ static void flow_entry_get_sain6_obj(struct flow_entry *n, sa->sin6_family = PF_INET6; memcpy(&sa->sin6_addr, SELFLD(dir, ip6_src_addr, ip6_dst_addr), - sizeof(SELFLD(dir, ip6_src_addr, ip6_dst_addr))); + sizeof(sa->sin6_addr)); } static void -- cgit v1.2.3-54-g00ecf