diff --git a/examples/rl-tcp/sim.cc b/examples/rl-tcp/sim.cc index 90ae9acb2a..7e76878516 100644 --- a/examples/rl-tcp/sim.cc +++ b/examples/rl-tcp/sim.cc @@ -104,7 +104,7 @@ int main (int argc, char *argv[]) cmd.AddValue ("nLeaf", "Number of left and right side leaf nodes", nLeaf); cmd.AddValue ("transport_prot", "Transport protocol to use: TcpNewReno, " "TcpHybla, TcpHighSpeed, TcpHtcp, TcpVegas, TcpScalable, TcpVeno, " - "TcpBic, TcpYeah, TcpIllinois, TcpWestwood, TcpWestwoodPlus, TcpLedbat, " + "TcpBic, TcpYeah, TcpIllinois, TcpWestwoodPlus, TcpLedbat, " "TcpLp, TcpRl, TcpRlTimeBased", transport_prot); cmd.AddValue ("error_p", "Packet error rate", error_p); cmd.AddValue ("bottleneck_bandwidth", "Bottleneck bandwidth", bottleneck_bandwidth); @@ -180,19 +180,9 @@ int main (int argc, char *argv[]) Config::SetDefault ("ns3::TcpL4Protocol::RecoveryType", TypeIdValue (TypeId::LookupByName (recovery))); // Select TCP variant - if (transport_prot.compare ("ns3::TcpWestwoodPlus") == 0) - { - // TcpWestwoodPlus is not an actual TypeId name; we need TcpWestwood here - Config::SetDefault ("ns3::TcpL4Protocol::SocketType", TypeIdValue (TcpWestwood::GetTypeId ())); - // the default protocol type in ns3::TcpWestwood is WESTWOOD - Config::SetDefault ("ns3::TcpWestwood::ProtocolType", EnumValue (TcpWestwood::WESTWOODPLUS)); - } - else - { - TypeId tcpTid; - NS_ABORT_MSG_UNLESS (TypeId::LookupByNameFailSafe (transport_prot, &tcpTid), "TypeId " << transport_prot << " not found"); - Config::SetDefault ("ns3::TcpL4Protocol::SocketType", TypeIdValue (TypeId::LookupByName (transport_prot))); - } + TypeId tcpTid; + NS_ABORT_MSG_UNLESS (TypeId::LookupByNameFailSafe (transport_prot, &tcpTid), "TypeId " << transport_prot << " not found"); + Config::SetDefault ("ns3::TcpL4Protocol::SocketType", TypeIdValue (TypeId::LookupByName (transport_prot))); // Configure the error model // Here we use RateErrorModel with packet error rate