changeset 1334:c8114a48837c

listenaddr must be malloced
author Matt Johnston <matt@ucc.asn.au>
date Tue, 16 May 2017 23:04:57 +0800
parents 6fafb500de88
children 253c08951b96
files svr-tcpfwd.c
diffstat 1 files changed, 1 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/svr-tcpfwd.c	Sat May 13 23:43:09 2017 +0800
+++ b/svr-tcpfwd.c	Tue May 16 23:04:57 2017 +0800
@@ -199,7 +199,7 @@
 	}
 	else
 	{
-		tcpinfo->listenaddr = request_addr;
+		tcpinfo->listenaddr = m_strdup(request_addr);
 	}
 
 	ret = listen_tcpfwd(tcpinfo);