diff options
author | Jelmer Vernooij <jelmer@samba.org> | 2008-10-08 02:21:49 +0200 |
---|---|---|
committer | Jelmer Vernooij <jelmer@samba.org> | 2008-10-08 02:21:49 +0200 |
commit | 99b2089752e202adbf4113b1854636e1db2f97c7 (patch) | |
tree | d5f4be4c26a1f39fc91beeebb75044d2ced89d41 /source4/auth/gensec/gensec.c | |
parent | 68837ff597bd39ff215ef30b4616692d2e31b1b4 (diff) | |
parent | 2024d87cf5ffa0633225ed189fa48f0f56151e7e (diff) | |
download | samba-99b2089752e202adbf4113b1854636e1db2f97c7.tar.gz samba-99b2089752e202adbf4113b1854636e1db2f97c7.tar.bz2 samba-99b2089752e202adbf4113b1854636e1db2f97c7.zip |
Merge branch 'master' of ssh://git.samba.org/data/git/samba
Diffstat (limited to 'source4/auth/gensec/gensec.c')
-rw-r--r-- | source4/auth/gensec/gensec.c | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/source4/auth/gensec/gensec.c b/source4/auth/gensec/gensec.c index 0edb34d740..5d57383d2a 100644 --- a/source4/auth/gensec/gensec.c +++ b/source4/auth/gensec/gensec.c @@ -490,6 +490,7 @@ static NTSTATUS gensec_start(TALLOC_CTX *mem_ctx, NT_STATUS_HAVE_NO_MEMORY(*gensec_security); (*gensec_security)->ops = NULL; + (*gensec_security)->private_data = NULL; ZERO_STRUCT((*gensec_security)->target); ZERO_STRUCT((*gensec_security)->peer_addr); @@ -525,6 +526,7 @@ _PUBLIC_ NTSTATUS gensec_subcontext_start(TALLOC_CTX *mem_ctx, (*gensec_security)->private_data = NULL; (*gensec_security)->subcontext = true; + (*gensec_security)->want_features = parent->want_features; (*gensec_security)->event_ctx = parent->event_ctx; (*gensec_security)->msg_ctx = parent->msg_ctx; (*gensec_security)->lp_ctx = parent->lp_ctx; @@ -1015,7 +1017,11 @@ _PUBLIC_ NTSTATUS gensec_update_recv(struct gensec_update_request *req, TALLOC_C _PUBLIC_ void gensec_want_feature(struct gensec_security *gensec_security, uint32_t feature) { - gensec_security->want_features |= feature; + if (!gensec_security->ops || !gensec_security->ops->want_feature) { + gensec_security->want_features |= feature; + return; + } + gensec_security->ops->want_feature(gensec_security, feature); } /** |