s4 dsdb util: add dsdb_domain_count
authorGary Lockyer <gary@catalyst.net.nz>
Wed, 13 Feb 2019 01:36:33 +0000 (14:36 +1300)
committerAndrew Bartlett <abartlet@samba.org>
Thu, 14 Feb 2019 04:03:23 +0000 (05:03 +0100)
commit12fcab1181efbda3e8b2ac8e471388e9a8d5c009
tree8af6cb4262a77b6c2c73f140577d210e880e2ba3
parentf3fd2d9457920b3da3e0ce6c1c6ee77be6849c65
s4 dsdb util: add dsdb_domain_count

This counts the number of objects that are in the domain,
provided a domain SID was supplied (otherwise it just
counts all the objects).

This routine avoids allocating memory for the full
result set by using a callback.

Signed-off-by: Gary Lockyer <gary@catalyst.net.nz>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
source4/dsdb/common/util.c