1
0
mirror of https://github.com/samba-team/samba.git synced 2025-03-12 20:58:37 +03:00

Revert "s4-ldb: fixed a memory leak"

This reverts commit c7358d989034c9d936c04f2a7e4f89db252b798e.
This commit is contained in:
Andrew Tridgell 2009-10-02 22:38:58 +10:00
parent 83e9b1c325
commit 81c193da09

View File

@ -135,7 +135,6 @@ static int ltdb_convert_from_idxptr(struct ldb_module *module, struct ldb_messag
return LDB_ERR_OPERATIONS_ERROR;
}
talloc_free(el->values);
*el = ptr->el;
if (ptr_out) {
@ -164,11 +163,7 @@ static int ltdb_update_idxptr(struct ldb_module *module, TALLOC_CTX *mem_ctx,
el->values = val2;
el->num_values = 1;
if (strcmp(el->name, LTDB_IDXPTR) == 0) {
abort();
}
el->values[0].data = talloc_memdup(val2, &ptr, sizeof(ptr));
el->values[0].data = talloc_memdup(el->values, &ptr, sizeof(ptr));
el->values[0].length = sizeof(ptr);
/* update the name */