s3-libads: Map LDAP_TIMELIMIT_EXCEEDED as NT_STATUS_IO_TIMEOUT
authorAndrew Bartlett <abartlet@samba.org>
Fri, 18 May 2012 07:38:48 +0000 (17:38 +1000)
committerJeremy Allison <jra@samba.org>
Sat, 26 May 2012 00:03:07 +0000 (02:03 +0200)
This allows Samba to then handle this error in the same way it would for RPC connections

Andrew Bartlett

Signed-off-by: Jeremy Allison <jra@samba.org>
source3/libads/ads_status.c

index fc489a9f00576df45d1ed2657f6ca803286e39dd..7465531404d63f732ad0d3164402505356f6e113 100644 (file)
@@ -82,6 +82,9 @@ NTSTATUS ads_ntstatus(ADS_STATUS status)
                if (status.err.rc == LDAP_SUCCESS) {
                        return NT_STATUS_OK;
                }
+               if (status.err.rc == LDAP_TIMELIMIT_EXCEEDED) {
+                       return NT_STATUS_IO_TIMEOUT;
+               }
                return NT_STATUS_LDAP(status.err.rc);
 #endif
 #ifdef HAVE_KRB5