summaryrefslogtreecommitdiff
path: root/source4/dsdb/samdb
diff options
context:
space:
mode:
authorAndrew Bartlett <abartlet@samba.org>2010-11-26 10:10:01 +1100
committerMatthias Dieter Wallnöfer <mdw@samba.org>2010-11-26 13:09:59 +0100
commit439a2d69831aea4a737e5e0e35226a551b11ad29 (patch)
treec68c80f144a37833b20c39df5f13c44b1453241b /source4/dsdb/samdb
parentbf52cffd2587615243a7101868a9038d9aa1b0c2 (diff)
downloadsamba-439a2d69831aea4a737e5e0e35226a551b11ad29.tar.gz
samba-439a2d69831aea4a737e5e0e35226a551b11ad29.tar.bz2
samba-439a2d69831aea4a737e5e0e35226a551b11ad29.zip
s4-objectclass Use a specific local variable name, not 'value'
This makes it clearer what the local variable in use here does. Andrew Bartlett Signed-off-by: Matthias Dieter Wallnöfer <mdw@samba.org>
Diffstat (limited to 'source4/dsdb/samdb')
-rw-r--r--source4/dsdb/samdb/ldb_modules/objectclass.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/source4/dsdb/samdb/ldb_modules/objectclass.c b/source4/dsdb/samdb/ldb_modules/objectclass.c
index 21f316400a..0eceaefce4 100644
--- a/source4/dsdb/samdb/ldb_modules/objectclass.c
+++ b/source4/dsdb/samdb/ldb_modules/objectclass.c
@@ -389,6 +389,7 @@ static int objectclass_add(struct ldb_module *module, struct ldb_request *req)
instanceType = ldb_msg_find_attr_as_uint(req->op.add.message,
"instanceType", 0);
if (!(instanceType & INSTANCE_TYPE_IS_NC_HEAD)) {
+ char *referral_uri;
/* When we are trying to readd the root basedn then
* this is denied, but with an interesting mechanism:
* there is generated a referral with the last
@@ -398,13 +399,13 @@ static int objectclass_add(struct ldb_module *module, struct ldb_request *req)
if (val == NULL) {
return ldb_operr(ldb);
}
- value = talloc_asprintf(req, "ldap://%s/%s", val->data,
- ldb_dn_get_linearized(req->op.add.message->dn));
- if (value == NULL) {
+ referral_uri = talloc_asprintf(req, "ldap://%s/%s", val->data,
+ ldb_dn_get_linearized(req->op.add.message->dn));
+ if (referral_uri == NULL) {
return ldb_module_oom(module);
}
- return ldb_module_send_referral(req, value);
+ return ldb_module_send_referral(req, referral_uri);
}
}