tcp: (fixes #2561) TCP can not use Connect after a BindToNetDevice
This commit is contained in:
@@ -47,6 +47,7 @@ Bugs fixed
|
||||
- Bug 2547 - dead assignments on various tcp congestion controls
|
||||
- Bug 2551 - wifi preamble should be part of TXVECTOR
|
||||
- Bug 2552 - Remove code duplication between Yans and Spectrum
|
||||
- Bug 2561 - TCP can not use Connect after a BindToNetDevice
|
||||
- Bug 2563 - Modify pybindgen version check to >= minimum version required
|
||||
- Bug 2564 - Simulation crashes when CtsTimeout is triggered for A-MPDU transmissions
|
||||
|
||||
|
||||
@@ -658,7 +658,7 @@ TcpSocketBase::Connect (const Address & address)
|
||||
NS_LOG_FUNCTION (this << address);
|
||||
|
||||
// If haven't do so, Bind() this socket first
|
||||
if (InetSocketAddress::IsMatchingType (address) && m_endPoint6 == 0)
|
||||
if (InetSocketAddress::IsMatchingType (address))
|
||||
{
|
||||
if (m_endPoint == 0)
|
||||
{
|
||||
@@ -681,7 +681,7 @@ TcpSocketBase::Connect (const Address & address)
|
||||
return -1;
|
||||
}
|
||||
}
|
||||
else if (Inet6SocketAddress::IsMatchingType (address) && m_endPoint == 0)
|
||||
else if (Inet6SocketAddress::IsMatchingType (address))
|
||||
{
|
||||
// If we are operating on a v4-mapped address, translate the address to
|
||||
// a v4 address and re-call this function
|
||||
@@ -707,7 +707,8 @@ TcpSocketBase::Connect (const Address & address)
|
||||
|
||||
// Get the appropriate local address and port number from the routing protocol and set up endpoint
|
||||
if (SetupEndpoint6 () != 0)
|
||||
{ // Route to destination does not exist
|
||||
{
|
||||
NS_LOG_ERROR ("Route to destination does not exist ?!");
|
||||
return -1;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user