diff options
-rw-r--r-- | hostfile.c | 4 | ||||
-rw-r--r-- | packet.c | 4 |
2 files changed, 5 insertions, 3 deletions
diff --git a/hostfile.c b/hostfile.c index e08339379..e1f826bdd 100644 --- a/hostfile.c +++ b/hostfile.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: hostfile.c,v 1.72 2018/06/06 18:29:18 markus Exp $ */ | 1 | /* $OpenBSD: hostfile.c,v 1.73 2018/07/16 03:09:13 djm Exp $ */ |
2 | /* | 2 | /* |
3 | * Author: Tatu Ylonen <ylo@cs.hut.fi> | 3 | * Author: Tatu Ylonen <ylo@cs.hut.fi> |
4 | * Copyright (c) 1995 Tatu Ylonen <ylo@cs.hut.fi>, Espoo, Finland | 4 | * Copyright (c) 1995 Tatu Ylonen <ylo@cs.hut.fi>, Espoo, Finland |
@@ -683,11 +683,11 @@ hostkeys_foreach(const char *path, hostkeys_foreach_fn *callback, void *ctx, | |||
683 | linenum++; | 683 | linenum++; |
684 | line[strcspn(line, "\n")] = '\0'; | 684 | line[strcspn(line, "\n")] = '\0'; |
685 | 685 | ||
686 | free(lineinfo.line); | ||
686 | sshkey_free(lineinfo.key); | 687 | sshkey_free(lineinfo.key); |
687 | memset(&lineinfo, 0, sizeof(lineinfo)); | 688 | memset(&lineinfo, 0, sizeof(lineinfo)); |
688 | lineinfo.path = path; | 689 | lineinfo.path = path; |
689 | lineinfo.linenum = linenum; | 690 | lineinfo.linenum = linenum; |
690 | free(lineinfo.line); | ||
691 | lineinfo.line = xstrdup(line); | 691 | lineinfo.line = xstrdup(line); |
692 | lineinfo.marker = MRK_NONE; | 692 | lineinfo.marker = MRK_NONE; |
693 | lineinfo.status = HKF_STATUS_OK; | 693 | lineinfo.status = HKF_STATUS_OK; |
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: packet.c,v 1.276 2018/07/09 21:03:30 markus Exp $ */ | 1 | /* $OpenBSD: packet.c,v 1.277 2018/07/16 03:09:13 djm Exp $ */ |
2 | /* | 2 | /* |
3 | * Author: Tatu Ylonen <ylo@cs.hut.fi> | 3 | * Author: Tatu Ylonen <ylo@cs.hut.fi> |
4 | * Copyright (c) 1995 Tatu Ylonen <ylo@cs.hut.fi>, Espoo, Finland | 4 | * Copyright (c) 1995 Tatu Ylonen <ylo@cs.hut.fi>, Espoo, Finland |
@@ -622,6 +622,8 @@ ssh_packet_close_internal(struct ssh *ssh, int do_close) | |||
622 | cipher_free(state->receive_context); | 622 | cipher_free(state->receive_context); |
623 | state->send_context = state->receive_context = NULL; | 623 | state->send_context = state->receive_context = NULL; |
624 | if (do_close) { | 624 | if (do_close) { |
625 | free(ssh->local_ipaddr); | ||
626 | ssh->local_ipaddr = NULL; | ||
625 | free(ssh->remote_ipaddr); | 627 | free(ssh->remote_ipaddr); |
626 | ssh->remote_ipaddr = NULL; | 628 | ssh->remote_ipaddr = NULL; |
627 | free(ssh->state); | 629 | free(ssh->state); |