summaryrefslogtreecommitdiff
path: root/ssh-add.c
diff options
context:
space:
mode:
authorDarren Tucker <dtucker@zip.com.au>2012-12-07 13:07:02 +1100
committerDarren Tucker <dtucker@zip.com.au>2012-12-07 13:07:02 +1100
commit8a96522482acd40af2e8a08696780a54c00b4feb (patch)
tree94fb15f82793c6c518852475235ee8a2dfda82fb /ssh-add.c
parentf9333d5246d979a448c5ff4d466de2fd2d286cfd (diff)
downloadopenssh-git-8a96522482acd40af2e8a08696780a54c00b4feb.tar.gz
- markus@cvs.openbsd.org 2012/12/05 15:42:52
[ssh-add.c] prevent double-free of comment; ok djm@
Diffstat (limited to 'ssh-add.c')
-rw-r--r--ssh-add.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/ssh-add.c b/ssh-add.c
index c8936e5a..00808470 100644
--- a/ssh-add.c
+++ b/ssh-add.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: ssh-add.c,v 1.104 2012/12/02 20:42:15 djm Exp $ */
+/* $OpenBSD: ssh-add.c,v 1.105 2012/12/05 15:42:52 markus Exp $ */
/*
* Author: Tatu Ylonen <ylo@cs.hut.fi>
* Copyright (c) 1995 Tatu Ylonen <ylo@cs.hut.fi>, Espoo, Finland
@@ -118,6 +118,7 @@ delete_file(AuthenticationConnection *ac, const char *filename, int key_only)
/* Now try to delete the corresponding certificate too */
free(comment);
+ comment = NULL;
xasprintf(&certpath, "%s-cert.pub", filename);
if ((cert = key_load_public(certpath, &comment)) == NULL)
goto out;