
On 12/06/2012 09:01 AM, Peter Krempa wrote:
On 12/06/12 15:37, Christophe Fergeau wrote:
virGetUserIDByName is documented as returning 1 if the username cannot be found. getpwnam_r is documented as returning: « 0 or ENOENT or ESRCH or EBADF or EPERM or ... The given name or uid was not found. »
+ if ((rc == EINTR) || (rc == EIO) || (rc == EMFILE) + || (rc == ENFILE) || (rc == ENOMEM)) {
We usualy write the operator at the end of the previous line of a linebreak.
Also (although I'm a bit late to the review, since you've already pushed), we don't use extra () when not needed. That is: if (rc == EINTR || rc == EIO || ...) is just fine, without having to bracket each branch of the conditional. -- Eric Blake eblake redhat com +1-919-301-3266 Libvirt virtualization library http://libvirt.org