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:
129298c
)
s4-ldb: ensure new dn_list elements are not owned by caller
author
Andrew Tridgell
<tridge@samba.org>
Thu, 22 Oct 2009 00:16:30 +0000
(11:16 +1100)
committer
Andrew Tridgell
<tridge@samba.org>
Thu, 22 Oct 2009 01:47:55 +0000
(12:47 +1100)
source4/lib/ldb/ldb_tdb/ldb_index.c
patch
|
blob
|
history
diff --git
a/source4/lib/ldb/ldb_tdb/ldb_index.c
b/source4/lib/ldb/ldb_tdb/ldb_index.c
index 606c24491ccb1d98d1af193ef5ce397fcc484620..a04fb1a8bd2416f1ebbee435a5b70111d0a0ea96 100644
(file)
--- a/
source4/lib/ldb/ldb_tdb/ldb_index.c
+++ b/
source4/lib/ldb/ldb_tdb/ldb_index.c
@@
-1105,7
+1105,7
@@
static int ltdb_index_add1(struct ldb_module *module, const char *dn,
talloc_free(list);
return LDB_ERR_OPERATIONS_ERROR;
}
- list->dn[list->count].data =
discard_const_p(unsigned char
, dn);
+ list->dn[list->count].data =
(uint8_t *)talloc_strdup(list->dn
, dn);
list->dn[list->count].length = strlen(dn);
list->count++;