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>
Fri, 23 Feb 2018 03:09:18 +0000 (04:09 +0100)
commit6548b82b5c1ed30ce14e17e4ba9d4bc24ab49c42
tree1b5767068248a19c274f25c14356d8bd79c332c0
parent43af57d8728883c5ddbe169e1483181246fb68a8
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>
source3/winbindd/winbindd_getgrent.c
source3/winbindd/winbindd_getpwent.c
source3/winbindd/winbindd_setgrent.c
source3/winbindd/winbindd_setpwent.c