fix getgrouplist when nscd reports an empty list
authorRich Felker <dalias@aerifal.cx>
Sun, 11 Oct 2020 00:04:18 +0000 (20:04 -0400)
committerRich Felker <dalias@aerifal.cx>
Thu, 15 Oct 2020 00:27:12 +0000 (20:27 -0400)
commitda845d52c5a8bee206fae899654e393d725a287f
treeef1471628b81efed33e5ac0c862226095eb1d0a8
parentb7bc966522d73e1dc420b5ee6fc7a2e78099a08c
fix getgrouplist when nscd reports an empty list

commit 500c6886c654fd45e4926990fee2c61d816be197 broke this by fixing
the behavior of fread to conform to the C standard; getgroupslist was
assuming the old behavior, that a request to read 1 member of length 0
would return 1, not 0.
src/passwd/getgrouplist.c