[libvirt] [PATCH 1/8] conf: Cleanup improper use of VIR_ERR_NO_SUPPORT in node_device_conf
Daniel P. Berrange
berrange at redhat.com
Wed Aug 24 21:50:49 UTC 2011
On Tue, Aug 23, 2011 at 05:39:38PM +0800, Osier Yang wrote:
> ---
> src/conf/node_device_conf.c | 2 +-
> 1 files changed, 1 insertions(+), 1 deletions(-)
>
> diff --git a/src/conf/node_device_conf.c b/src/conf/node_device_conf.c
> index 548bbff..4803e2a 100644
> --- a/src/conf/node_device_conf.c
> +++ b/src/conf/node_device_conf.c
> @@ -1277,7 +1277,7 @@ virNodeDeviceGetWWNs(virNodeDeviceDefPtr def,
> }
>
> if (cap == NULL) {
> - virNodeDeviceReportError(VIR_ERR_NO_SUPPORT,
> + virNodeDeviceReportError(VIR_ERR_OPERATION_INVALID,
> "%s", _("Device is not a fibre channel HBA"));
> ret = -1;
> } else if (*wwnn == NULL || *wwpn == NULL) {
I think either CONFIG_SUPPORTED or just INTERNAL_ERROR is best
here.
Daniel
--
|: http://berrange.com -o- http://www.flickr.com/photos/dberrange/ :|
|: http://libvirt.org -o- http://virt-manager.org :|
|: http://autobuild.org -o- http://search.cpan.org/~danberr/ :|
|: http://entangle-photo.org -o- http://live.gnome.org/gtk-vnc :|
More information about the libvir-list
mailing list