summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMatthias Dieter Wallnöfer <mdw@samba.org>2010-10-31 11:03:59 +0100
committerMatthias Dieter Wallnöfer <mdw@samba.org>2010-10-31 18:44:06 +0000
commit771b10a421c287bb191192da632e73e5d1458cce (patch)
tree0e06af15ae82a561e69b45fc2f0f156ea362976f
parent8de1d727f18b28f660b6f88b14f307841c4ae6cb (diff)
downloadsamba-771b10a421c287bb191192da632e73e5d1458cce.tar.gz
samba-771b10a421c287bb191192da632e73e5d1458cce.tar.bz2
samba-771b10a421c287bb191192da632e73e5d1458cce.zip
s4:samldb LDB module - check for the number of results after a search operation
Should always be done.
-rw-r--r--source4/dsdb/samdb/ldb_modules/samldb.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/source4/dsdb/samdb/ldb_modules/samldb.c b/source4/dsdb/samdb/ldb_modules/samldb.c
index 9b6d6e03cc..f4b7043e32 100644
--- a/source4/dsdb/samdb/ldb_modules/samldb.c
+++ b/source4/dsdb/samdb/ldb_modules/samldb.c
@@ -1067,6 +1067,9 @@ static int samldb_prim_group_change(struct samldb_ctx *ac)
if (ret != LDB_SUCCESS) {
return ret;
}
+ if (res->count != 1) {
+ return ldb_operr(ldb);
+ }
/* Finds out the DN of the old primary group */