git.samba.org
/
abartlet
/
samba.git
/
.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
aa2cd74
)
s4:ldb Change ldb_request_add_control to the normal 'for loop' pattern
author
Andrew Bartlett
<abartlet@samba.org>
Wed, 11 Nov 2009 08:24:08 +0000
(19:24 +1100)
committer
Andrew Bartlett
<abartlet@samba.org>
Wed, 11 Nov 2009 21:11:22 +0000
(08:11 +1100)
source4/lib/ldb/common/ldb_controls.c
patch
|
blob
|
history
diff --git
a/source4/lib/ldb/common/ldb_controls.c
b/source4/lib/ldb/common/ldb_controls.c
index 5276ac091da4b45d1428379652faa452fc0a5531..82bd34bda5f72d7539437e0b3bbbd79de0748f8b 100644
(file)
--- a/
source4/lib/ldb/common/ldb_controls.c
+++ b/
source4/lib/ldb/common/ldb_controls.c
@@
-168,12
+168,11
@@
int ldb_request_add_control(struct ldb_request *req, const char *oid, bool criti
struct ldb_control **ctrls;
struct ldb_control *ctrl;
- for (n=0; req->controls && req->controls[n];) {
+ for (n=0; req->controls && req->controls[n];
n++
) {
/* having two controls of the same OID makes no sense */
if (strcmp(oid, req->controls[n]->oid) == 0) {
return LDB_ERR_ATTRIBUTE_OR_VALUE_EXISTS;
}
- n++;
}
ctrls = talloc_array(req,