mirror of
https://git.openldap.org/openldap/openldap.git
synced 2025-12-23 08:09:34 -05:00
Fix attrs handling
This commit is contained in:
parent
ede3abc8c7
commit
e78a0930c8
1 changed files with 7 additions and 3 deletions
|
|
@ -36,6 +36,7 @@ tcl_back_search (
|
||||||
char *attrs_tcl = NULL, *suf_tcl, *results, *command;
|
char *attrs_tcl = NULL, *suf_tcl, *results, *command;
|
||||||
int i, err = 0, code;
|
int i, err = 0, code;
|
||||||
struct tclinfo *ti = (struct tclinfo *) be->be_private;
|
struct tclinfo *ti = (struct tclinfo *) be->be_private;
|
||||||
|
char **sattrs = NULL;
|
||||||
Entry *e;
|
Entry *e;
|
||||||
|
|
||||||
if (ti->ti_search == NULL) {
|
if (ti->ti_search == NULL) {
|
||||||
|
|
@ -44,9 +45,12 @@ tcl_back_search (
|
||||||
return (-1);
|
return (-1);
|
||||||
}
|
}
|
||||||
|
|
||||||
for (i = 0; attrs != NULL && attrs[i] != NULL; i++);
|
for (i = 0; attrs != NULL && attrs[i] != NULL; i++)
|
||||||
if (i > 0)
|
charray_add(&sattrs, attrs[i]->bv_val);
|
||||||
attrs_tcl = Tcl_Merge (i, attrs);
|
if (i > 0) {
|
||||||
|
attrs_tcl = Tcl_Merge (i, sattrs);
|
||||||
|
charray_free(sattrs);
|
||||||
|
}
|
||||||
|
|
||||||
for (i = 0; be->be_suffix[i] != NULL; i++);
|
for (i = 0; be->be_suffix[i] != NULL; i++);
|
||||||
suf_tcl = Tcl_Merge (i, be->be_suffix);
|
suf_tcl = Tcl_Merge (i, be->be_suffix);
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue