Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
Nadezhda Ivanova
OpenLDAP
Commits
4f8a99e1
Commit
4f8a99e1
authored
Apr 06, 2003
by
Howard Chu
Browse files
ITS#2423 plug some memleaks
parent
2ee7488d
Changes
2
Hide whitespace changes
Inline
Side-by-side
clients/tools/common.c
View file @
4f8a99e1
...
...
@@ -670,6 +670,7 @@ tool_bind( LDAP *ld )
sasl_mech
,
NULL
,
NULL
,
sasl_flags
,
lutil_sasl_interact
,
defaults
);
lutil_sasl_freedefs
(
defaults
);
if
(
rc
!=
LDAP_SUCCESS
)
{
ldap_perror
(
ld
,
"ldap_sasl_interactive_bind_s"
);
exit
(
EXIT_FAILURE
);
...
...
clients/tools/ldapsearch.c
View file @
4f8a99e1
...
...
@@ -915,6 +915,8 @@ getNextPage:
#endif
ldap_unbind
(
ld
);
sasl_done
();
ldap_pvt_tls_destroy
();
return
(
rc
);
}
...
...
@@ -1120,6 +1122,7 @@ static int dosearch(
}
done:
ldap_msgfree
(
res
);
#ifdef LDAP_CONTROL_PAGEDRESULTS
if
(
pageSize
!=
0
)
{
npagedresponses
=
npagedresponses
+
nresponses
;
...
...
@@ -1521,24 +1524,28 @@ static int print_result(
fprintf
(
stderr
,
"%s (%d)
\n
"
,
ldap_err2string
(
err
),
err
);
}
if
(
matcheddn
&&
*
matcheddn
)
{
if
(
matcheddn
)
{
if
(
*
matcheddn
)
{
if
(
!
ldif
)
{
write_ldif
(
LDIF_PUT_VALUE
,
"matchedDN"
,
matcheddn
,
strlen
(
matcheddn
)
);
}
else
{
fprintf
(
stderr
,
"Matched DN: %s
\n
"
,
matcheddn
);
}
}
ber_memfree
(
matcheddn
);
}
if
(
text
&&
*
text
)
{
if
(
text
)
{
if
(
*
text
)
{
if
(
!
ldif
)
{
write_ldif
(
LDIF_PUT_TEXT
,
"text"
,
text
,
strlen
(
text
)
);
}
else
{
fprintf
(
stderr
,
"Additional information: %s
\n
"
,
text
);
}
}
ber_memfree
(
text
);
}
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment