summaryrefslogtreecommitdiff
path: root/canohost.c
diff options
context:
space:
mode:
authorColin Watson <cjwatson@debian.org>2013-09-14 15:43:03 +0100
committerColin Watson <cjwatson@debian.org>2013-09-14 15:43:03 +0100
commit8faf8c84430cf3c19705b1d9f8889d256e7fd1fd (patch)
treee6cb74192adb00fda5e4d1457547851d7e0d86af /canohost.c
parent328b60656f29db6306994d7498dede386ec2d1c3 (diff)
parentc41345ad7ee5a22689e2c009595e85fa27b4b39a (diff)
merge 6.3p1
Diffstat (limited to 'canohost.c')
-rw-r--r--canohost.c10
1 files changed, 4 insertions, 6 deletions
diff --git a/canohost.c b/canohost.c
index dabd8a31a..69e8e6f6d 100644
--- a/canohost.c
+++ b/canohost.c
@@ -1,4 +1,4 @@
1/* $OpenBSD: canohost.c,v 1.66 2010/01/13 01:20:20 dtucker Exp $ */ 1/* $OpenBSD: canohost.c,v 1.67 2013/05/17 00:13: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
@@ -41,7 +41,7 @@ static int cached_port = -1;
41 41
42/* 42/*
43 * Return the canonical name of the host at the other end of the socket. The 43 * Return the canonical name of the host at the other end of the socket. The
44 * caller should free the returned string with xfree. 44 * caller should free the returned string.
45 */ 45 */
46 46
47static char * 47static char *
@@ -323,10 +323,8 @@ get_local_name(int fd)
323void 323void
324clear_cached_addr(void) 324clear_cached_addr(void)
325{ 325{
326 if (canonical_host_ip != NULL) { 326 free(canonical_host_ip);
327 xfree(canonical_host_ip); 327 canonical_host_ip = NULL;
328 canonical_host_ip = NULL;
329 }
330 cached_port = -1; 328 cached_port = -1;
331} 329}
332 330