[libvirt] [PATCH] network_conf.c: correct the value of the 'result' variable

Eric Blake eblake at redhat.com
Fri Nov 1 15:05:40 UTC 2013


On 11/01/2013 03:54 AM, Hongwei Bi wrote:
> 2013/11/1 Eric Blake <eblake at redhat.com>:
>> [off-list]
>>
>> On 10/31/2013 06:20 PM, Hongwei Bi wrote:
>>
>> Your system clock is off.  From your headers:

I'm a bit surprised that you re-added the list regarding an off-list
suggestion; but thank you for fixing your system clock.

> It seems that there is no need to add this patch. But the caller
> virNetworkDefFormatInternal() has a check of the return value which is
> described as " if (virNetworkDNSDefFormat(buf, &def->dns) < 0) ". So I
> think we should at least change one or the other.

No.  Just becuase virNetworkDNSDefFormat() currently has no failure
paths does not mean that it will not gain some in the future.  It's
safer to keep the caller code checking for errors, even if none
currently happen.  The existing code is fine as is.

-- 
Eric Blake   eblake redhat com    +1-919-301-3266
Libvirt virtualization library http://libvirt.org

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 621 bytes
Desc: OpenPGP digital signature
URL: <http://listman.redhat.com/archives/libvir-list/attachments/20131101/fb6ee304/attachment-0001.sig>


More information about the libvir-list mailing list