diff --git a/modules/extra/m_ldap.cpp b/modules/extra/m_ldap.cpp
index dbf7a4a..6c90917 100644
--- a/modules/extra/m_ldap.cpp
+++ b/modules/extra/m_ldap.cpp
@@ -277,6 +277,9 @@ class LDAPService : public LDAPProvider, public Thread, public Condition
  private:
 	void Timeout()
 	{
+		// we have to update Anope::CurTime here because its only updated in the socketengines
+		// and this->Run() blocks the anope main thread.
+		Anope::CurTime = time(NULL);
 		this->Lock();
 		for (query_queue::iterator it = this->queries.begin(), it_end = this->queries.end(); it != it_end;)
 		{
