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
Joe Martin
OpenLDAP
Commits
a8cf2fb1
Commit
a8cf2fb1
authored
Sep 18, 2014
by
Ian Puleston
Committed by
Quanah Gibson-Mount
Oct 11, 2017
Browse files
ITS#8167 Fix non-blocking TLS with referrals
parent
49e7fb84
Changes
1
Hide whitespace changes
Inline
Side-by-side
libraries/libldap/tls2.c
View file @
a8cf2fb1
...
...
@@ -854,7 +854,7 @@ ldap_int_tls_start ( LDAP *ld, LDAPConn *conn, LDAPURLDesc *srv )
* Use non-blocking io during SSL Handshake when a timeout is configured
*/
if
(
ld
->
ld_options
.
ldo_tm_net
.
tv_sec
>=
0
)
{
ber_sockbuf_ctrl
(
ld
->
ld_
sb
,
LBER_SB_OPT_SET_NONBLOCK
,
sb
);
ber_sockbuf_ctrl
(
sb
,
LBER_SB_OPT_SET_NONBLOCK
,
(
void
*
)
1
);
ber_sockbuf_ctrl
(
sb
,
LBER_SB_OPT_GET_FD
,
&
sd
);
tv
=
ld
->
ld_options
.
ldo_tm_net
;
tv0
=
tv
;
...
...
@@ -889,7 +889,7 @@ ldap_int_tls_start ( LDAP *ld, LDAPConn *conn, LDAPURLDesc *srv )
break
;
}
else
{
/* ldap_int_poll called ldap_pvt_ndelay_off */
ber_sockbuf_ctrl
(
ld
->
ld_
sb
,
LBER_SB_OPT_SET_NONBLOCK
,
sb
);
ber_sockbuf_ctrl
(
sb
,
LBER_SB_OPT_SET_NONBLOCK
,
(
void
*
)
1
);
ret
=
ldap_int_tls_connect
(
ld
,
conn
,
host
);
if
(
ret
>
0
)
{
/* need to call tls_connect once more */
struct
timeval
curr_time_tv
,
delta_tv
;
...
...
@@ -937,7 +937,7 @@ ldap_int_tls_start ( LDAP *ld, LDAPConn *conn, LDAPURLDesc *srv )
}
}
if
(
ld
->
ld_options
.
ldo_tm_net
.
tv_sec
>=
0
)
{
ber_sockbuf_ctrl
(
ld
->
ld_
sb
,
LBER_SB_OPT_SET_NONBLOCK
,
NULL
);
ber_sockbuf_ctrl
(
sb
,
LBER_SB_OPT_SET_NONBLOCK
,
NULL
);
}
#endif
/* LDAP_USE_NON_BLOCKING_TLS */
...
...
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