Skip to content

Commit

Permalink
Make schat use DCCBindHost
Browse files Browse the repository at this point in the history
  • Loading branch information
kylef committed Jun 1, 2011
1 parent c635cae commit d71da02
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions modules/schat.cpp
Expand Up @@ -170,7 +170,7 @@ class CSChat : public CModule
pSock->SetPemLocation(m_sPemFile); pSock->SetPemLocation(m_sPemFile);


u_short iPort = m_pManager->ListenRand(pSock->GetSockName() + "::LISTENER", u_short iPort = m_pManager->ListenRand(pSock->GetSockName() + "::LISTENER",
m_pUser->GetLocalIP(), true, SOMAXCONN, pSock, 60); m_pUser->GetLocalDCCIP(), true, SOMAXCONN, pSock, 60);


if (iPort == 0) { if (iPort == 0) {
PutModule("Failed to start chat!"); PutModule("Failed to start chat!");
Expand All @@ -180,7 +180,7 @@ class CSChat : public CModule
stringstream s; stringstream s;
s << "PRIVMSG " << sArgs << " :\001"; s << "PRIVMSG " << sArgs << " :\001";
s << "DCC SCHAT chat "; s << "DCC SCHAT chat ";
s << CUtils::GetLongIP(m_pUser->GetLocalIP()); s << CUtils::GetLongIP(m_pUser->GetLocalDCCIP());
s << " " << iPort << "\001"; s << " " << iPort << "\001";


PutIRC(s.str()); PutIRC(s.str());
Expand Down Expand Up @@ -341,7 +341,7 @@ class CSChat : public CModule
{ {
CSChatSock *p = new CSChatSock(this, sNick, CUtils::GetIP(iIP), iPort, 60); CSChatSock *p = new CSChatSock(this, sNick, CUtils::GetIP(iIP), iPort, 60);
m_pManager->Connect(CUtils::GetIP(iIP), iPort, p->GetSockName(), 60, m_pManager->Connect(CUtils::GetIP(iIP), iPort, p->GetSockName(), 60,
true, m_pUser->GetLocalIP(), p); true, m_pUser->GetLocalDCCIP(), p);
RemTimer("Remove " + sNick); // delete any associated timer to this nick RemTimer("Remove " + sNick); // delete any associated timer to this nick
} }


Expand Down

0 comments on commit d71da02

Please sign in to comment.