winbind: call lp_winbind_enum_{users,groups}() already in set{pw,gr}ent()
authorStefan Metzmacher <metze@samba.org>
Fri, 16 Feb 2018 15:09:58 +0000 (16:09 +0100)
committerStefan Metzmacher <metze@samba.org>
Tue, 27 Feb 2018 15:00:13 +0000 (16:00 +0100)
commitf9103fc0bd2d6b737e0605fe1ceae702cd48b117
tree35b5f74a81aebda422172d67836520866589bed2
parent4c1e32d5abf89ccf24e2679177e7dd1134861186
winbind: call lp_winbind_enum_{users,groups}() already in set{pw,gr}ent()

This way we don't keep winbindd_cli_state->{pw,gr}ent_state arround forever,
if the client forgets an explicit end{pw,gr}ent().

This allows client_is_idle() return true in more cases.

BUG: https://bugzilla.samba.org/show_bug.cgi?id=13293

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Volker Lendecke <vl@samba.org>
(cherry picked from commit 6548b82b5c1ed30ce14e17e4ba9d4bc24ab49c42)
source3/winbindd/winbindd_getgrent.c
source3/winbindd/winbindd_getpwent.c
source3/winbindd/winbindd_setgrent.c
source3/winbindd/winbindd_setpwent.c