From 64e267c2feaecd9c2f0a60d548ccd2ff0ee37879 Mon Sep 17 00:00:00 2001 From: Michael Adam Date: Fri, 11 Apr 2014 18:25:44 +0200 Subject: [PATCH] autorid: make the checks for bumping num_mapped identical for alloc and rid case in idmap_autorid_sids_to_unixids() Signed-off-by: Michael Adam Reviewed-by: Stefan Metzmacher --- source3/winbindd/idmap_autorid.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/source3/winbindd/idmap_autorid.c b/source3/winbindd/idmap_autorid.c index 0bdc96dd477..b66caec9022 100644 --- a/source3/winbindd/idmap_autorid.c +++ b/source3/winbindd/idmap_autorid.c @@ -465,7 +465,7 @@ static NTSTATUS idmap_autorid_sids_to_unixids(struct idmap_domain *dom, goto failure; } - if (ids[i]->status == ID_MAPPED) { + if (NT_STATUS_IS_OK(ret) && ids[i]->status == ID_MAPPED) { num_mapped++; } @@ -524,7 +524,7 @@ static NTSTATUS idmap_autorid_sids_to_unixids(struct idmap_domain *dom, goto failure; } - if (NT_STATUS_IS_OK(ret)) { + if (NT_STATUS_IS_OK(ret) && ids[i]->status == ID_MAPPED) { num_mapped++; } } -- 2.11.4.GIT