build: tolerate unlimited group size
build: tolerate unlimited group size

POSIX allows sysconf(_SC_GETPW_R_SIZE_MAX) to return -1 if there
is no fixed limit, and requires ERANGE errors to track real size.
Model our behavior after the example in POSIX itself:
http://pubs.opengroup.org/onlinepubs/9699919799/functions/getpwuid_r.html

Also, on error for get*_r functions, errno is undefined, and the
real error was the return value.

* src/util/util.c (virGetUserEnt, virGetUserID, virGetGroupID)
(virSetUIDGID):  Cope with sysconf failure or too small buffer.
Reported by Matthias Bolte.

zhlcindy/libvirt-1.1.4-maintain,taget/libvirt,emaste/libvirt,VenkatDatta/libvirt,agx/libvirt,jardasgit/libvirt,soulxu/libvirt-xuhj,bjzhang/libvirt,cbosdo/libvirt,rlaager/libvirt,zhlcindy/libvirt-1.1.4-maintain,fabianfreyer/libvirt,shugaoye/libvirt,leilihh/libvirt,taget/libvirt,kantai/libvirt-vfork,jeckersb/libvirt,andreabolognani/libvirt,emaste/libvirt,jardasgit/libvirt,taget/libvirt,zhlcindy/libvirt-1.1.4-maintain,nertpinx/libvirt,warewolf/libvirt,libvirt/libvirt,danwent/libvirt-ovs,rmarwaha/libvirt,fabianfreyer/libvirt,rmarwaha/libvirt,novel/fbsd-libvirt,jeckersb/libvirt,siboulet/libvirt-openvz,shugaoye/libvirt,bjzhang/libvirt,andreabolognani/libvirt,cbosdo/libvirt,trainstack/libvirt,dumbbell/libvirt,rlaager/libvirt,trainstack/libvirt,elmarco/libvirt,bjzhang/libvirt,zhlcindy/libvirt-1.1.4-maintain,leilihh/libvirt,jeckersb/libvirt,warewolf/libvirt,libvirt/libvirt,soulxu/libvirt-xuhj,crobinso/libvirt,nertpinx/libvirt,shugaoye/libvirt,olafhering/libvirt,jardasgit/libvirt,iam-TJ/libvirt,kantai/libvirt-vfork,emaste/libvirt,jfehlig/libvirt,foomango/libvirt,datto/libvirt,leilihh/libvirt,dumbbell/libvirt,wiedi/libvirt,rmarwaha/libvirt1,taget/libvirt,rmarwaha/libvirt,jardasgit/libvirt,nertpinx/libvirt,rmarwaha/libvirt1,danwent/libvirt-ovs,novel/fbsd-libvirt,agx/libvirt,soulxu/libvirt-xuhj,usc-isi/libvirt,novel/fbsd-libvirt,zippy2/libvirt,andreabolognani/libvirt,rmarwaha/libvirt1,novel/fbsd-libvirt,trainstack/libvirt,cbosdo/libvirt,siboulet/libvirt-openvz,nertpinx/libvirt,jeckersb/libvirt,libvirt/libvirt,danwent/libvirt-ovs,eskultety/libvirt,elmarco/libvirt,novel/fbsd-libvirt,datto/libvirt,datto/libvirt,eskultety/libvirt,usc-isi/libvirt,rlaager/libvirt,elmarco/libvirt,foomango/libvirt,siboulet/libvirt-openvz,usc-isi/libvirt,danwent/libvirt-ovs,emaste/libvirt,eskultety/libvirt,fabianfreyer/libvirt,andreabolognani/libvirt,VenkatDatta/libvirt,trainstack/libvirt,zhlcindy/libvirt-1.1.4-maintain,agx/libvirt,dumbbell/libvirt,iam-TJ/libvirt,kantai/libvirt-vfork,leilihh/libvirt,zippy2/libvirt,datto/libvirt,usc-isi/libvirt,eskultety/libvirt,rmarwaha/libvirt1,elmarco/libvirt,wiedi/libvirt,emaste/libvirt,fabianfreyer/libvirt,novel/fbsd-libvirt,olafhering/libvirt,leilihh/libvirt,wiedi/libvirt,eskultety/libvirt,taget/libvirt,soulxu/libvirt-xuhj,zippy2/libvirt,warewolf/libvirt,olafhering/libvirt,wiedi/libvirt,trainstack/libvirt,rlaager/libvirt,iam-TJ/libvirt,emaste/libvirt,rlaager/libvirt,dumbbell/libvirt,iam-TJ/libvirt,olafhering/libvirt,agx/libvirt,crobinso/libvirt,novel/fbsd-libvirt,trainstack/libvirt,wiedi/libvirt,usc-isi/libvirt,rmarwaha/libvirt,foomango/libvirt,zippy2/libvirt,novel/fbsd-libvirt,wiedi/libvirt,kantai/libvirt-vfork,soulxu/libvirt-xuhj,iam-TJ/libvirt,trainstack/libvirt,warewolf/libvirt,foomango/libvirt,iam-TJ/libvirt,datto/libvirt,jfehlig/libvirt,crobinso/libvirt,jardasgit/libvirt,jfehlig/libvirt,jeckersb/libvirt,VenkatDatta/libvirt,bjzhang/libvirt,cbosdo/libvirt,warewolf/libvirt,agx/libvirt,shugaoye/libvirt,cbosdo/libvirt,jfehlig/libvirt,siboulet/libvirt-openvz,foomango/libvirt,rmarwaha/libvirt,dumbbell/libvirt,danwent/libvirt-ovs,bjzhang/libvirt,rmarwaha/libvirt1,kantai/libvirt-vfork,wiedi/libvirt,shugaoye/libvirt,crobinso/libvirt,rmarwaha/libvirt1,leilihh/libvirt,jeckersb/libvirt,emaste/libvirt,dumbbell/libvirt,iam-TJ/libvirt,VenkatDatta/libvirt,elmarco/libvirt,warewolf/libvirt,andreabolognani/libvirt,libvirt/libvirt,VenkatDatta/libvirt,nertpinx/libvirt,fabianfreyer/libvirt,warewolf/libvirt,jeckersb/libvirt,siboulet/libvirt-openvz,novel/fbsd-libvirt,rmarwaha/libvirt