diff --git a/RELEASE_NOTES b/RELEASE_NOTES index 115d5bace..d322cb10d 100644 --- a/RELEASE_NOTES +++ b/RELEASE_NOTES @@ -25,11 +25,13 @@ New user-visible features Bugs fixed ---------- - Bug 1643 - NdiscCache creation and existence checks +- Bug 1646 - ICMPv6 Redirect are sent from global address instead of link-local - Bug 1662 - m_type not set for Ipv6OptionRouterAlertHeader - Bug 1678 - C++11 compliance problem with std::pair" - Bug 1683 - IPv6 autoconfigured don't use *infinite* lifetimes - Bug 1669 - ns-3 should support binding two and three (possibly more) arguments - Bug 1689 - IPv6 shouldn't add a default gateway without checking the Router lifetime +- Bug 1700 - Ipv6RawSocket does not honor the bound address when sending packets Known issues ------------ diff --git a/src/internet/model/ipv6-raw-socket-impl.cc b/src/internet/model/ipv6-raw-socket-impl.cc index d5597ecb7..482dd7ebc 100644 --- a/src/internet/model/ipv6-raw-socket-impl.cc +++ b/src/internet/model/ipv6-raw-socket-impl.cc @@ -244,7 +244,14 @@ int Ipv6RawSocketImpl::SendTo (Ptr p, uint32_t flags, const Address& toA } } - ipv6->Send (p, route->GetSource (), dst, m_protocol, route); + if (m_src.IsAny ()) + { + ipv6->Send (p, route->GetSource (), dst, m_protocol, route); + } + else + { + ipv6->Send (p, m_src, dst, m_protocol, route); + } // Return only payload size (as Linux does). return p->GetSize () - hdr.GetSerializedSize (); } diff --git a/src/internet/test/ipv6-raw-test.cc b/src/internet/test/ipv6-raw-test.cc index 084c997c8..a3c90947f 100644 --- a/src/internet/test/ipv6-raw-test.cc +++ b/src/internet/test/ipv6-raw-test.cc @@ -121,7 +121,7 @@ void Ipv6RawSocketImplTest::ReceivePkt2 (Ptr socket) m_receivedPacket2 = socket->RecvFrom (std::numeric_limits::max (), 0, addr); NS_ASSERT (availableData == m_receivedPacket2->GetSize ()); Inet6SocketAddress v6addr = Inet6SocketAddress::ConvertFrom (addr); - NS_TEST_EXPECT_MSG_EQ (v6addr.GetIpv6 (),Ipv6Address ("fe80:0000:0000:0000:0200:00ff:fe00:0003"), "recvfrom"); + NS_TEST_EXPECT_MSG_EQ (v6addr.GetIpv6 (),Ipv6Address ("2001:0db8:0000:0000:0000:0000:0000:0002"), "recvfrom"); } void