Lin Ma 317e3b2865 util: Return a virArpTablePtr when the nlmsghdr for loop is over
commit b00c9c39 removed the label end_of_netlink_messages and 'return
table' statement, It causes the function virArpTableGet doesn't return
a proper virArpTable pointer.

How to reproduce:
 # virsh domiflist sles12sp3
Interface  Type       Source     Model       MAC
-------------------------------------------------------
vnet0      network    default    virtio      52:54:00💿02:e6

 # virsh domifaddr sles12sp3 --source arp
error: Failed to query for interfaces addresses
error: An error occurred, but the cause is unknown

It seems that the "if (nh->nlmsg_type == NLMSG_DONE)" statement won't be
meted. So this patch adds 'return table' when the iterations of nlmsghdr
for loop is over.

Signed-off-by: Lin Ma <lma@suse.com>
Reviewed-by: Chen Hanxiao <chenhanxiao@gmail.com>
Reviewed-by: John Ferlan <jferlan@redhat.com>
2018-09-14 11:18:28 -04:00
..
2018-08-24 13:23:36 +02:00
2018-08-24 13:23:36 +02:00
2017-11-03 13:24:12 +01:00
2017-07-26 15:31:25 +02:00
2017-05-16 16:48:30 +02:00
2017-06-12 19:11:30 -04:00
2018-04-01 17:42:29 +02:00
2018-03-12 16:30:49 +01:00
2018-07-27 15:47:45 +02:00
2018-07-15 12:09:09 +02:00
2018-09-05 15:51:42 +02:00
2018-09-05 15:51:42 +02:00
2018-03-14 12:46:26 +01:00
2018-07-27 15:47:45 +02:00
2018-07-27 15:47:45 +02:00
2017-12-05 11:28:19 +01:00
2017-11-03 13:24:12 +01:00
2018-05-29 15:42:03 +02:00
2018-05-29 15:42:03 +02:00
2017-11-03 13:24:12 +01:00