Re: [libvirt] [PATCH] util: refactor virNetlinkCommand to fix several bugs / style problems

2014-05-20 Thread Laine Stump
On 05/16/2014 06:24 PM, Ján Tomko wrote: > On 05/13/2014 01:51 PM, Laine Stump wrote: >> Inspired by a simpler patch from "Wangrui (K) ". >> >> A submitted patch pointed out that virNetlinkCommand() was doing an >> improper typecast of the return value from nl_recv() (int to >> unsigned), causing i

Re: [libvirt] [PATCH] util: refactor virNetlinkCommand to fix several bugs / style problems

2014-05-16 Thread Ján Tomko
On 05/13/2014 01:51 PM, Laine Stump wrote: > Inspired by a simpler patch from "Wangrui (K) ". > > A submitted patch pointed out that virNetlinkCommand() was doing an > improper typecast of the return value from nl_recv() (int to > unsigned), causing it to miss error returns, and that even after >

Re: [libvirt] [PATCH] util: refactor virNetlinkCommand to fix several bugs / style problems

2014-05-13 Thread Wangrui (K)
Good improvement especially in coding style from which I learned difference between rc and ret. :) > -Original Message- > From: Laine Stump [mailto:la...@laine.org] > Sent: Tuesday, May 13, 2014 7:52 PM > To: libvir-list@redhat.com; Wangrui (K); Yanqiangjun; Zhangbo (Oscar) > Subject: [PA

[libvirt] [PATCH] util: refactor virNetlinkCommand to fix several bugs / style problems

2014-05-13 Thread Laine Stump
Inspired by a simpler patch from "Wangrui (K) ". A submitted patch pointed out that virNetlinkCommand() was doing an improper typecast of the return value from nl_recv() (int to unsigned), causing it to miss error returns, and that even after remedying that problem, virNetlinkCommand() was calling