- allocate correct buffer size for channel info, rather than sizeof(pointer).

--HG--
extra : convert_revision : 0f2848d140f76a1dabbe5930e9b0a5d4f282f90b
This commit is contained in:
Matt Johnston 2005-04-24 10:30:33 +00:00
parent 8bc7b0ff5a
commit 51be125ff9

View File

@ -94,7 +94,7 @@ static int cli_localtcp(unsigned int listenport, const char* remoteaddr,
TRACE(("enter cli_localtcp: %d %s %d", listenport, remoteaddr, TRACE(("enter cli_localtcp: %d %s %d", listenport, remoteaddr,
remoteport)); remoteport));
tcpinfo = (struct TCPListener*)m_malloc(sizeof(struct TCPListener*)); tcpinfo = (struct TCPListener*)m_malloc(sizeof(struct TCPListener));
tcpinfo->sendaddr = m_strdup(remoteaddr); tcpinfo->sendaddr = m_strdup(remoteaddr);
tcpinfo->sendport = remoteport; tcpinfo->sendport = remoteport;
tcpinfo->listenport = listenport; tcpinfo->listenport = listenport;