]> git.ipfire.org Git - thirdparty/libvirt.git/commit
util: make interface.c functions consistently return < 0 on error
authorLaine Stump <laine@laine.org>
Fri, 22 Jul 2011 02:48:32 +0000 (22:48 -0400)
committerLaine Stump <laine@laine.org>
Fri, 22 Jul 2011 13:27:07 +0000 (09:27 -0400)
commitf7e18208e19adaacd0d84b8a47c999318f0f6192
tree6f80487dcf225d5344da7409cd795215198bf6e5
parent637711cbdfb83b915eefb0178135244f7d96fe47
util: make interface.c functions consistently return < 0 on error

All of the functions in util/interface.c were returning 0 on success,
but some returned -1 on error, and some returned a positive value
(usually the value of errno, but sometimes just 1). Libvirt's standard
is to return < 0 on error (in the case of functions that need to
return errno, -errno is returned.

This patch modifies all functions in interface.c to consistently
return < 0 on error, and makes changes to callers of those functions
where necessary.
src/nwfilter/nwfilter_gentech_driver.c
src/nwfilter/nwfilter_learnipaddr.c
src/util/interface.c
src/util/macvtap.c