gensec: move event context from gensec_*_init() to gensec_update()
[nivanova/samba-autobuild/.git] / source4 / libcli / ldap / ldap_bind.c
index e5e8cbadb4c4bfc5976aa338d275af3698793e13..f167f17de9669fa5d67fcd3c9f6d10cfd6374f07 100644 (file)
@@ -225,7 +225,6 @@ _PUBLIC_ NTSTATUS ldap_bind_sasl(struct ldap_connection *conn,
        gensec_init();
 
        status = gensec_client_start(conn, &conn->gensec,
-                                    conn->event.event_ctx, 
                                     lpcfg_gensec_settings(conn, lp_ctx));
        if (!NT_STATUS_IS_OK(status)) {
                DEBUG(0, ("Failed to start GENSEC engine (%s)\n", nt_errstr(status)));
@@ -319,6 +318,7 @@ _PUBLIC_ NTSTATUS ldap_bind_sasl(struct ldap_connection *conn,
                int result = LDAP_OTHER;
        
                status = gensec_update(conn->gensec, tmp_ctx,
+                                      conn->event.event_ctx,
                                       input,
                                       &output);
                /* The status value here, from GENSEC is vital to the security