Four IPv4 CalcChecksum attributes (which enable the computation of
checksums that are disabled by default) have been collapsed into one global
From a3bc8265a824f6a7261100c69fdb122984e49bb7 Mon Sep 17 00:00:00 2001
From: Andrey Hippo
Date: Thu, 2 Jul 2009 15:11:03 +0200
Subject: [PATCH 03/46] download url should point to allinone tarball
---
RELEASE_NOTES | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/RELEASE_NOTES b/RELEASE_NOTES
index 3235305a3..4264e8903 100644
--- a/RELEASE_NOTES
+++ b/RELEASE_NOTES
@@ -14,7 +14,7 @@ Release 3.5
Availability
------------
This release is immediately available from:
-http://www.nsnam.org/releases/ns-3.5.tar.bz2
+http://www.nsnam.org/releases/ns-allinone-3.5.tar.bz2
Supported platforms
-------------------
@@ -73,7 +73,7 @@ Release 3.4
Availability
------------
This release is immediately available from:
-http://www.nsnam.org/releases/ns-3.4.tar.bz2
+http://www.nsnam.org/releases/ns-allinone-3.4.tar.bz2
Supported platforms
-------------------
From cfc93e2f83807003d2a4ae0ef8bbe09c581889ce Mon Sep 17 00:00:00 2001
From: Andrey Hippo
Date: Thu, 2 Jul 2009 15:13:27 +0200
Subject: [PATCH 04/46] escape html special characters
---
CHANGES.html | 82 ++++++++++++++++++++++++++--------------------------
1 file changed, 41 insertions(+), 41 deletions(-)
diff --git a/CHANGES.html b/CHANGES.html
index 62da83d7a..43ab5de41 100644
--- a/CHANGES.html
+++ b/CHANGES.html
@@ -81,7 +81,7 @@ fragmentation and reassembly.
Ipv4Interface::GetMtu () deleted
The Ipv4Interface API is private to internet-stack module; this method
-was just a pass-through to GetDevice ()->GetMtu ().
+was just a pass-through to GetDevice ()->GetMtu ().
To accommodate support for the radiotap and prism headers in PCAP traces, the interface for promiscuos mode sniff in the wifi device was changed. The new implementation was heavily inspired by the way the madwifi driver handles monitor mode. A distinction between TX and RX events is introduced, to account for the fact that different information is to be put in the radiotap/prism header (e.g., RSSI and noise make sense only for RX packets). The following are the relevant modifications to the WifiPhy class:
In the above method, the isTx parameter is to be used to differentiate between TX and RX packets. For an example of how to implement these callbacks, see the implementation of PcapSniffTxEvent and PcapSniffRxEvent in src/helper/yans-wifi-helper.cc
@@ -181,18 +181,18 @@ the general nature of these calls (synchronous routing lookup for
locally originated packets, and an asynchronous, callback-based lookup
for forwarded packets) is still the same.
At the helper API level, one often gets an address from an interface
container. We preserve the legacy GetAddress (uint32_t i) but it
@@ -293,16 +293,16 @@ Ipv4Address Ipv4InterfaceContainer::GetAddress (uint32_t i)
New WifiMacHelper objects
The type of wifi MAC is now set by two new specific helpers, NqosWifiMacHelper for non QoS MACs and QosWifiMacHelper for Qos MACs. They are passed as argument to WifiHelper::Install methods.
to avoid the kind of bugs reported in
bug 273.
@@ -648,7 +648,7 @@ public:
- void SetPort (uint16_t port);
+ UdpEchoServerHelper (uint16_t port);
+
-+ void SetAttribute (std::string name, const AttributeValue &value);
++ void SetAttribute (std::string name, const AttributeValue &value);
ApplicationContainer Install (NodeContainer c);
class UdpEchoClientHelper
@@ -657,8 +657,8 @@ public:
- UdpEchoClientHelper ();
+ UdpEchoClientHelper (Ipv4Address ip, uint16_t port);
- void SetRemote (Ipv4Address ip, uint16_t port);
-- void SetAppAttribute (std::string name, const AttributeValue &value);
-+ void SetAttribute (std::string name, const AttributeValue &value);
+- void SetAppAttribute (std::string name, const AttributeValue &value);
++ void SetAttribute (std::string name, const AttributeValue &value);
ApplicationContainer Install (NodeContainer c);
From 2cb774905738fabc442a29bd546962d1f38c68cd Mon Sep 17 00:00:00 2001
From: Mathieu Lacage
Date: Thu, 2 Jul 2009 15:32:37 +0200
Subject: [PATCH 05/46] document how a GlobalValue can be set from the
command-line and with an environment variable
---
src/core/global-value.h | 8 ++++++++
1 file changed, 8 insertions(+)
diff --git a/src/core/global-value.h b/src/core/global-value.h
index fb957621e..a40d2244f 100644
--- a/src/core/global-value.h
+++ b/src/core/global-value.h
@@ -35,6 +35,14 @@ namespace ns3 {
*
* Instances of this class are expected to be allocated as static
* global variables and should be used to store configurable global state.
+ * GlobalValues can be set directly by calling ns3::GlobalValue::SetValue
+ * but they can also be set through the NS_GLOBAL_VALUE environment variable.
+ * For example, NS_GLOBAL_VALUE='Name=Value;OtherName=OtherValue;' would set
+ * global values Name and OtherName to Value and OtherValue respectively.
+ *
+ * Users of the ns3::CommandLine class also get the ability to set global
+ * values through commandline arguments to their program: --Name=Value will
+ * set global value Name to Value.
*/
class GlobalValue
{
From 35a025338e6e8feb75417fe6150094cecc2c9093 Mon Sep 17 00:00:00 2001
From: Mathieu Lacage
Date: Thu, 2 Jul 2009 15:33:08 +0200
Subject: [PATCH 06/46] add an anchor for each generate documentation for a
GlobalValue
---
utils/print-introspected-doxygen.cc | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/utils/print-introspected-doxygen.cc b/utils/print-introspected-doxygen.cc
index 4aba6acef..0928a27d1 100644
--- a/utils/print-introspected-doxygen.cc
+++ b/utils/print-introspected-doxygen.cc
@@ -402,7 +402,7 @@ int main (int argc, char *argv[])
{
StringValue val;
(*i)->GetValue (val);
- std::cout << "
" << std::endl;
}
std::cout << "" << std::endl
<< "*/" << std::endl;
From db1bc136af1d27f92f1cff8aa35738b767f99d21 Mon Sep 17 00:00:00 2001
From: Mathieu Lacage
Date: Thu, 2 Jul 2009 15:33:27 +0200
Subject: [PATCH 07/46] use the new global value anchors to reference RngSeed
and RndRun
---
src/core/random-variable.h | 5 ++---
1 file changed, 2 insertions(+), 3 deletions(-)
diff --git a/src/core/random-variable.h b/src/core/random-variable.h
index 3f102dcb4..715309eff 100644
--- a/src/core/random-variable.h
+++ b/src/core/random-variable.h
@@ -115,9 +115,8 @@ public:
* NS-3 has a rich set of random number generators.
* Class RandomVariable defines the base class functionalty
* required for all random number generators. By default, the underlying
- * generator is seeded with the time of day, and then deterministically
- * creates a sequence of seeds for each subsequent generator that is created.
- * The rest of the documentation outlines how to change this behavior.
+ * generator is seeded all the time with the same seed value and run number
+ * coming from the ns3::GlobalValue \ref GlobalValueRngSeed "RngSeed" and \ref GlobalValueRngRun "RngRun".
*/
class RandomVariable
{
From 3da4a8e2418121565c9ae1f6f412b7adb44a017a Mon Sep 17 00:00:00 2001
From: Mathieu Lacage
Date: Thu, 2 Jul 2009 16:33:35 +0200
Subject: [PATCH 08/46] add file to avoid stupid warning.
---
doc/doxygen.conf | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/doc/doxygen.conf b/doc/doxygen.conf
index 1460ba842..d4e391e58 100644
--- a/doc/doxygen.conf
+++ b/doc/doxygen.conf
@@ -514,7 +514,8 @@ INPUT_ENCODING = UTF-8
# *.hpp *.h++ *.idl *.odl *.cs *.php *.php3 *.inc *.m *.mm *.py *.f90
FILE_PATTERNS = *.h \
- *.tcc
+ *.tcc \
+ node-list.cc
# The RECURSIVE tag can be used to turn specify whether or not subdirectories
# should be searched for input files as well. Possible values are YES and NO.
From 138b79f906e2667856565d39703b927cfaa0e4cd Mon Sep 17 00:00:00 2001
From: Mathieu Lacage
Date: Thu, 2 Jul 2009 16:38:53 +0200
Subject: [PATCH 09/46] get rid of some doxygen warnings
---
src/applications/udp-echo/udp-echo-client.h | 10 +++++-----
src/common/pcap-writer.h | 2 +-
src/devices/wifi/wifi-phy.h | 4 ++--
3 files changed, 8 insertions(+), 8 deletions(-)
diff --git a/src/applications/udp-echo/udp-echo-client.h b/src/applications/udp-echo/udp-echo-client.h
index 05569946e..c8514640b 100644
--- a/src/applications/udp-echo/udp-echo-client.h
+++ b/src/applications/udp-echo/udp-echo-client.h
@@ -51,7 +51,7 @@ public:
* to the server). The contents of the data are set to unspecified (don't
* care) by this call.
*
- * \warn If you have set the fill data for the echo client using one of the
+ * \warning If you have set the fill data for the echo client using one of the
* SetFill calls, this will undo those effects.
*
* \param dataSize The size of the echo data you want to sent.
@@ -61,7 +61,7 @@ public:
/**
* Get the number of data bytes that will be sent to the server.
*
- * \warn The number of bytes may be modified by calling any one of the
+ * \warning The number of bytes may be modified by calling any one of the
* SetFill methods. If you have called SetFill, then the number of
* data bytes will correspond to the size of an initialized data buffer.
* If you have not called a SetFill method, the number of data bytes will
@@ -75,7 +75,7 @@ public:
* Set the data fill of the packet (what is sent as data to the server) to
* the zero-terminated contents of the fill string string.
*
- * \warn The size of resulting echo packets will be automatically adjusted
+ * \warning The size of resulting echo packets will be automatically adjusted
* to reflect the size of the fill string -- this means that the PacketSize
* attribute may be changed as a result of this call.
*
@@ -88,7 +88,7 @@ public:
* the repeated contents of the fill byte. i.e., the fill byte will be
* used to initialize the contents of the data packet.
*
- * \warn The size of resulting echo packets will be automatically adjusted
+ * \warning The size of resulting echo packets will be automatically adjusted
* to reflect the dataSize parameter -- this means that the PacketSize
* attribute may be changed as a result of this call.
*
@@ -105,7 +105,7 @@ public:
* accomplished by setting the fillSize set to your desired dataSize
* (and providing an appropriate buffer).
*
- * \warn The size of resulting echo packets will be automatically adjusted
+ * \warning The size of resulting echo packets will be automatically adjusted
* to reflect the dataSize parameter -- this means that the PacketSize
* attribute of the Application may be changed as a result of this call.
*
diff --git a/src/common/pcap-writer.h b/src/common/pcap-writer.h
index 08e4153b4..d99754915 100644
--- a/src/common/pcap-writer.h
+++ b/src/common/pcap-writer.h
@@ -118,7 +118,7 @@ public:
* on a nearby channel.
* @param rate the PHY data rate in units of 500kbps (i.e., the same
* units used both for the radiotap and for the prism header)
- * @param isPreambleShort true if short preamble is used, false otherwise
+ * @param isShortPreamble true if short preamble is used, false otherwise
* @param isTx true if packet is being transmitted, false when
* packet is being received
* @param signalDbm signal power in dBm
diff --git a/src/devices/wifi/wifi-phy.h b/src/devices/wifi/wifi-phy.h
index 9fb67a90a..e061827a9 100644
--- a/src/devices/wifi/wifi-phy.h
+++ b/src/devices/wifi/wifi-phy.h
@@ -309,7 +309,7 @@ public:
* on a nearby channel.
* @param rate the PHY data rate in units of 500kbps (i.e., the same
* units used both for the radiotap and for the prism header)
- * @param isPreambleShort true if short preamble is used, false otherwise
+ * @param isShortPreamble true if short preamble is used, false otherwise
* @param signalDbm signal power in dBm
* @param noiseDbm noise power in dBm
*/
@@ -331,7 +331,7 @@ public:
* on a nearby channel.
* @param rate the PHY data rate in units of 500kbps (i.e., the same
* units used both for the radiotap and for the prism header)
- * @param isPreambleShort true if short preamble is used, false otherwise
+ * @param isShortPreamble true if short preamble is used, false otherwise
*/
void NotifyPromiscSniffTx (Ptr packet, uint16_t channelFreqMhz, uint32_t rate, bool isShortPreamble);
From 6f9dada4303eb1b853065053887923d6f684f527 Mon Sep 17 00:00:00 2001
From: Tom Henderson
Date: Thu, 2 Jul 2009 21:57:00 -0700
Subject: [PATCH 10/46] some fixes to the manual for IPv4 refactoring
---
doc/manual/node.texi | 135 +++++++++++++++++-----------------------
doc/manual/routing.texi | 16 +++--
2 files changed, 69 insertions(+), 82 deletions(-)
diff --git a/doc/manual/node.texi b/doc/manual/node.texi
index 61fbf727f..a79694df6 100644
--- a/doc/manual/node.texi
+++ b/doc/manual/node.texi
@@ -121,86 +121,74 @@ ARP, UDP, TCP, and other related protocols.
Internet Nodes are not subclasses of class Node; they are simply Nodes
that have had a bunch of IPv4-related
objects aggregated to them. They can be put together by hand, or
-via a helper function @code{AddInternetStack ()} which does the
-following:
+via a helper function @code{InternetStackHelper::Install ()} which does the
+following to all nodes passed in as arguments:
@verbatim
-void AddInternetStack (Ptr node)
+void
+InternetStackHelper::Install (Ptr node) const
{
- // Create layer-3 protocols
- Ptr ipv4 = CreateObject ();
- Ptr arp = CreateObject ();
- ipv4->SetNode (node);
- arp->SetNode (node);
+ if (node->GetObject () != 0)
+ {
+ NS_FATAL_ERROR ("InternetStackHelper::Install(): Aggregating "
+ "an InternetStack to a node with an existing Ipv4 object");
+ return;
+ }
- // Create an L4 demux
- Ptr ipv4L4Demux = CreateObject ();
+ CreateAndAggregateObjectFromTypeId (node, "ns3::ArpL3Protocol");
+ CreateAndAggregateObjectFromTypeId (node, "ns3::Ipv4L3Protocol");
+ CreateAndAggregateObjectFromTypeId (node, "ns3::Icmpv4L4Protocol");
+ CreateAndAggregateObjectFromTypeId (node, "ns3::UdpL4Protocol");
+ node->AggregateObject (m_tcpFactory.Create