summaryrefslogtreecommitdiff
path: root/key.c
diff options
context:
space:
mode:
authorDamien Miller <djm@mindrot.org>2013-12-07 11:29:09 +1100
committerDamien Miller <djm@mindrot.org>2013-12-07 11:29:09 +1100
commitca570a519cb846da61d002c7f46fa92e39c83e45 (patch)
tree17d249a3ac08328caf2c743e440612249300bfd6 /key.c
parent3cccc0e155229a2f2d86b6df40bd4559b4f960ff (diff)
- djm@cvs.openbsd.org 2013/12/07 00:19:15
[key.c] set k->cert = NULL after freeing it
Diffstat (limited to 'key.c')
-rw-r--r--key.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/key.c b/key.c
index 236e02676..814f9a001 100644
--- a/key.c
+++ b/key.c
@@ -1,4 +1,4 @@
1/* $OpenBSD: key.c,v 1.108 2013/12/06 13:34:54 markus Exp $ */ 1/* $OpenBSD: key.c,v 1.110 2013/12/07 00:19:15 djm Exp $ */
2/* 2/*
3 * read_bignum(): 3 * read_bignum():
4 * Copyright (c) 1995 Tatu Ylonen <ylo@cs.hut.fi>, Espoo, Finland 4 * Copyright (c) 1995 Tatu Ylonen <ylo@cs.hut.fi>, Espoo, Finland
@@ -1955,6 +1955,7 @@ key_drop_cert(Key *k)
1955 return -1; 1955 return -1;
1956 } 1956 }
1957 cert_free(k->cert); 1957 cert_free(k->cert);
1958 k->cert = NULL;
1958 k->type = key_type_plain(k->type); 1959 k->type = key_type_plain(k->type);
1959 return 0; 1960 return 0;
1960} 1961}