arping: coverity woe on COPY_PASTE_ERROR 73/31873/2
authorSteven Luong <sluong@cisco.com>
Fri, 2 Apr 2021 15:51:17 +0000 (08:51 -0700)
committerMatthew Smith <mgsmith@netgate.com>
Mon, 5 Apr 2021 14:33:30 +0000 (14:33 +0000)
coverity is trying to outsmart human by guessing on COPY_PASTE_ERROR.
Have it your way.

Type: fix

Signed-off-by: Steven Luong <sluong@cisco.com>
Change-Id: I0239c9745e21384aebbaf9e977962746b81ded58

src/plugins/arping/arping.c

index 6c5836b..14f9258 100644 (file)
@@ -178,7 +178,7 @@ VLIB_NODE_FN (arping_input_node)
                  aif1->recv.from4.ip4.as_u32 =
                    arp1->ip4_over_ethernet[0].ip4.as_u32;
                  clib_memcpy_fast (&aif1->recv.from4.mac,
-                                   &arp0->ip4_over_ethernet[0].mac, 6);
+                                   &arp1->ip4_over_ethernet[0].mac, 6);
                  aif1->reply_count++;
                }
            }