Merge rev 1016 from x-x

'only listen on local IP'


git-svn-id: https://znc.svn.sourceforge.net/svnroot/znc/trunk@822 726aef4b-f618-498e-8847-2d620e286838
This commit is contained in:
psychon
2007-08-07 22:48:25 +00:00
parent 5b1e3bf600
commit 9ab4c3c384

View File

@@ -904,7 +904,7 @@ bool CUser::SendFile(const CString& sRemoteNick, const CString& sFileName, const
return false;
}
unsigned short uPort = CZNC::Get().GetManager().ListenAllRand("DCC::LISTEN::" + sRemoteNick, false, SOMAXCONN, pSock, 120);
unsigned short uPort = CZNC::Get().GetManager().ListenRand("DCC::LISTEN::" + sRemoteNick, GetLocalIP(), false, SOMAXCONN, pSock, 120);
if (GetNick().CaseCmp(sRemoteNick) == 0) {
PutUser(":" + GetStatusPrefix() + "status!znc@znc.com PRIVMSG " + sRemoteNick + " :\001DCC SEND " + pFile->GetShortName() + " " + CString(CUtils::GetLongIP(GetLocalIP())) + " "