title: How can I cause ldap_simple_bind_s to timeout?
body: <p>We recently had a problem with our test LDAP server - it was hung and wouldn't respond to requests. As a result, our application hung forever* while trying to bind to it. This only happened on Unix machines - on Windows, the <code>ldap_simple_bind_s</code> call timed out after about 30 seconds.</p>
  
  <p>* I don't know if it really was <em>forever</em>, but it was at least several minutes.</p>
  
  <p>I added calls to <code>ldap_set_option</code>, trying both <code>LDAP_OPT_TIMEOUT</code> and <code>LDAP_OPT_NETWORK_TIMEOUT</code>, but the bind call still hung. Is there any way to make <code>ldap_simple_bind_s</code> time out after some period of time of my choosing?</p>