Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
openldap
OpenLDAP
Commits
1a3fd9f7
Commit
1a3fd9f7
authored
Sep 30, 2013
by
Emily Backes
Committed by
Quanah Gibson-Mount
Oct 08, 2013
Browse files
ITS
#7712
Fix lock ordering in libldap abandon
parent
b9ce8460
Changes
1
Hide whitespace changes
Inline
Side-by-side
libraries/libldap/abandon.c
View file @
1a3fd9f7
...
@@ -279,9 +279,14 @@ start_again:;
...
@@ -279,9 +279,14 @@ start_again:;
if
(
lr
!=
NULL
)
{
if
(
lr
!=
NULL
)
{
if
(
sendabandon
||
lr
->
lr_status
==
LDAP_REQST_WRITING
)
{
if
(
sendabandon
||
lr
->
lr_status
==
LDAP_REQST_WRITING
)
{
/* release ld_req_mutex while grabbing ld_conn_mutex to
* prevent deadlock.
*/
LDAP_MUTEX_UNLOCK
(
&
ld
->
ld_req_mutex
);
LDAP_MUTEX_LOCK
(
&
ld
->
ld_conn_mutex
);
LDAP_MUTEX_LOCK
(
&
ld
->
ld_conn_mutex
);
ldap_free_connection
(
ld
,
lr
->
lr_conn
,
0
,
1
);
ldap_free_connection
(
ld
,
lr
->
lr_conn
,
0
,
1
);
LDAP_MUTEX_UNLOCK
(
&
ld
->
ld_conn_mutex
);
LDAP_MUTEX_UNLOCK
(
&
ld
->
ld_conn_mutex
);
LDAP_MUTEX_LOCK
(
&
ld
->
ld_req_mutex
);
}
}
if
(
origid
==
msgid
)
{
if
(
origid
==
msgid
)
{
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a 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