Page 1 of 1

libnat bugs

Posted: Sat Dec 31, 2011 2:44 am
by zjhangtian
反馈一个libnat的BUG
wftpserver用了libnat库做端口映射功能
但是libnat里面有个BUG,当获取到的xml里面ControlURL为空的时候,libnat会崩溃
崩溃在 upnp.c 里面的
/* if the control_url contains the http protocol string,
then don't prepend the base url to it */
if(strncmp(xdescdat.control_url, HTTP_PROTOCOL_STRING,
strlen(HTTP_PROTOCOL_STRING)) == 0) {

xdescdat.control_url 为 NULL
strncmp一执行就崩溃了

所以在路由表有BUG的机器上,端口映射一开,wftpserver就再也起不来了
希望修复一下

Re: libnat bugs

Posted: Sat Jan 07, 2012 7:43 am
by FTP
Thanks for your bug report! We will fix it in the next release.