]> git.ipfire.org Git - thirdparty/libvirt.git/commit
virnetdev: Check for root in virNetDevGetFeatures
authorJohn Ferlan <jferlan@redhat.com>
Wed, 4 Nov 2015 15:26:16 +0000 (10:26 -0500)
committerJohn Ferlan <jferlan@redhat.com>
Fri, 6 Nov 2015 16:19:07 +0000 (11:19 -0500)
commitd0a3a1ff929e8e2d6a82a4e0e3cfb72bfa63c928
tree1bd1fa39e2eee42707bc4b915263483bfeec5419
parent9efab5da1668bff2dee986f8d4443af9d900e76d
virnetdev: Check for root in virNetDevGetFeatures

Since the SIOCETHTOOL ioctl only works for privileged daemons, if called
when not root, then virNetDevGetFeatures will VIR_DEBUG a message and
return 0 as if the functions were not available for the architecture.
This effectively returns an empty bitmap indicating no features available.

Introduced by commit id 'c9027d8f4'

Signed-off-by: John Ferlan <jferlan@redhat.com>
src/util/virnetdev.c