tldap: Mark server down if read failed
authorVolker Lendecke <vl@samba.org>
Fri, 18 Dec 2015 15:31:46 +0000 (16:31 +0100)
committerGünther Deschner <gd@samba.org>
Wed, 3 Feb 2016 14:04:11 +0000 (15:04 +0100)
This matches tldap_msg_sent

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Guenther Deschner <gd@samba.org>
source3/lib/tldap.c

index d8b4f241bac520dceb52fb8186686b428145fcd6..4c2319c8beab156fcfff8260fb491b00037d6f7f 100644 (file)
@@ -589,6 +589,7 @@ static void tldap_msg_received(struct tevent_req *subreq)
        received = read_ldap_recv(subreq, talloc_tos(), &inbuf, &err);
        TALLOC_FREE(subreq);
        if (received == -1) {
+               ld->server_down = true;
                status = TLDAP_SERVER_DOWN;
                goto fail;
        }