Skip to content

Its#9468 fix hang in test079

Howard Chu requested to merge hyc/openldap:its9468 into master

Apparently it's possible for a new connection to be created and then the expire task to be scheduled before the first Bind operation on the new connection occurs. In that case the lc->lc_time is still 0, and conn_expire() reschedules with a negative time value, causing an infinite loop in the runq scheduler. Previously this would not happen if StartTLS was set on the connection, since ldap_prepare_conn handles that request immediately and initializes the timestamp in that case.

Now ldap_prepare_conn always inits the timestamp. Additional patch from Tero Saarni not strictly needed to fix this issue, but saves some redundant expire processing.

This supersedes !333 (closed)

Edited by Howard Chu

Merge request reports