diff options
author | dtucker <dtucker> | 2003-10-08 07:37:58 +0000 |
---|---|---|
committer | dtucker <dtucker> | 2003-10-08 07:37:58 +0000 |
commit | 8ac5422638cf15357c00fb412ed46491c7fdc4c2 (patch) | |
tree | 74b68ec49c900a59e91a83a9679cb7a8ef4d925a /sshconnect2.c | |
parent | e76885ba98e5c92ab7b8b2a64d6e32731fba98ae (diff) | |
download | openssh-8ac5422638cf15357c00fb412ed46491c7fdc4c2.tar.gz |
- deraadt@cvs.openbsd.org 2003/10/07 21:58:28
[sshconnect2.c]
set ptr to NULL after free
Diffstat (limited to 'sshconnect2.c')
-rw-r--r-- | sshconnect2.c | 13 |
1 files changed, 9 insertions, 4 deletions
diff --git a/sshconnect2.c b/sshconnect2.c index 4e3ae2de..2ef4201c 100644 --- a/sshconnect2.c +++ b/sshconnect2.c @@ -23,7 +23,7 @@ */ #include "includes.h" -RCSID("$OpenBSD: sshconnect2.c,v 1.125 2003/10/07 01:47:27 dtucker Exp $"); +RCSID("$OpenBSD: sshconnect2.c,v 1.126 2003/10/07 21:58:28 deraadt Exp $"); #include "openbsd-compat/sys-queue.h" @@ -358,6 +358,7 @@ void input_userauth_banner(int type, u_int32_t seq, void *ctxt) { char *msg, *lang; + debug3("input_userauth_banner"); msg = packet_get_string(NULL); lang = packet_get_string(NULL); @@ -373,10 +374,14 @@ input_userauth_success(int type, u_int32_t seq, void *ctxt) Authctxt *authctxt = ctxt; if (authctxt == NULL) fatal("input_userauth_success: no authentication context"); - if (authctxt->authlist) + if (authctxt->authlist) { xfree(authctxt->authlist); - if (authctxt->methoddata) + authctxt->authlist = NULL; + } + if (authctxt->methoddata) { xfree(authctxt->methoddata); + authctxt->methoddata = NULL; + } authctxt->success = 1; /* break out */ } @@ -609,7 +614,7 @@ input_gssapi_token(int type, u_int32_t plen, void *ctxt) packet_check_eom(); - status=ssh_gssapi_init_ctx(gssctxt, options.gss_deleg_creds, + status = ssh_gssapi_init_ctx(gssctxt, options.gss_deleg_creds, &recv_tok, &send_tok, NULL); xfree(recv_tok.value); |