NS_LOG_FUNCTION -> NS_LOG_FUNCTION_NOARGS and NS_LOG_PARAMS -> NS_LOG_FUNCTION
authorMathieu Lacage <mathieu.lacage@sophia.inria.fr>
Tue, 15 Apr 2008 15:10:53 -0700
changeset 2983 e3a416fe9dd5
parent 2982 a7e3e54c7e94
child 2984 27b183b18d4d
NS_LOG_FUNCTION -> NS_LOG_FUNCTION_NOARGS and NS_LOG_PARAMS -> NS_LOG_FUNCTION
src/applications/onoff/onoff-application.cc
src/applications/udp-echo/udp-echo-client.cc
src/applications/udp-echo/udp-echo-server.cc
src/common/error-model.cc
src/common/packet-metadata.cc
src/core/log.cc
src/core/log.h
src/devices/csma/csma-channel.cc
src/devices/csma/csma-net-device.cc
src/devices/point-to-point/point-to-point-channel.cc
src/devices/point-to-point/point-to-point-net-device.cc
src/helper/ipv4-address-helper.cc
src/internet-node/arp-ipv4-interface.cc
src/internet-node/arp-l3-protocol.cc
src/internet-node/ipv4-end-point-demux.cc
src/internet-node/ipv4-interface.cc
src/internet-node/ipv4-l3-protocol.cc
src/internet-node/ipv4-loopback-interface.cc
src/internet-node/ipv4-static-routing.cc
src/internet-node/tcp-l4-protocol.cc
src/internet-node/tcp-socket.cc
src/internet-node/udp-l4-protocol.cc
src/internet-node/udp-socket.cc
src/mobility/random-direction-2d-mobility-model.cc
src/node/channel.cc
src/node/drop-tail-queue.cc
src/node/ipv4-address-generator.cc
src/node/node-list.cc
src/node/packet-socket.cc
src/node/queue.cc
src/node/socket.cc
src/routing/global-routing/candidate-queue.cc
src/routing/global-routing/global-route-manager-impl.cc
src/routing/global-routing/global-router-interface.cc
src/routing/olsr/routing-table.cc
--- a/src/applications/onoff/onoff-application.cc	Mon Apr 14 16:39:26 2008 -0700
+++ b/src/applications/onoff/onoff-application.cc	Tue Apr 15 15:10:53 2008 -0700
@@ -91,7 +91,7 @@
 
 OnOffApplication::OnOffApplication ()
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   m_socket = 0;
   m_connected = false;
   m_residualBits = 0;
@@ -101,14 +101,13 @@
 
 OnOffApplication::~OnOffApplication()
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 }
 
 void 
 OnOffApplication::SetMaxBytes(uint32_t maxBytes)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << maxBytes);
+  NS_LOG_FUNCTION (this << maxBytes);
   m_maxBytes = maxBytes;
 }
 
@@ -116,7 +115,7 @@
 void
 OnOffApplication::DoDispose (void)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 
   m_socket = 0;
   // chain up
@@ -126,7 +125,7 @@
 // Application Methods
 void OnOffApplication::StartApplication() // Called at time specified by Start
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 
   // Create the socket if not already
   if (!m_socket)
@@ -146,7 +145,7 @@
 
 void OnOffApplication::StopApplication() // Called at time specified by Stop
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 
   if (m_sendEvent.IsRunning ())
     { // Cancel the pending send packet event
@@ -161,14 +160,14 @@
 // Event handlers
 void OnOffApplication::StartSending()
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 
   ScheduleNextTx();  // Schedule the send packet event
 }
 
 void OnOffApplication::StopSending()
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 
   Simulator::Cancel(m_sendEvent);
 }
@@ -176,7 +175,7 @@
 // Private helpers
 void OnOffApplication::ScheduleNextTx()
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 
   if (m_maxBytes == 0 || m_totBytes < m_maxBytes)
     {
@@ -196,7 +195,7 @@
 
 void OnOffApplication::ScheduleStartEvent()
 {  // Schedules the event to start sending data (switch to the "On" state)
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 
   Time offInterval = Seconds(m_offTime.GetValue());
   NS_LOG_LOGIC ("start at " << offInterval);
@@ -205,7 +204,7 @@
 
 void OnOffApplication::ScheduleStopEvent()
 {  // Schedules the event to stop sending data (switch to "Off" state)
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 
   Time onInterval = Seconds(m_onTime.GetValue());
   NS_LOG_LOGIC ("stop at " << onInterval);
@@ -215,7 +214,7 @@
   
 void OnOffApplication::SendPacket()
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   NS_LOG_LOGIC ("sending packet at " << Simulator::Now());
   NS_ASSERT (m_sendEvent.IsExpired ());
   Ptr<Packet> packet = Create<Packet> (m_pktSize);
@@ -229,7 +228,7 @@
 
 void OnOffApplication::ConnectionSucceeded(Ptr<Socket>)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 
   m_connected = true;
   ScheduleStartEvent();
@@ -237,7 +236,7 @@
   
 void OnOffApplication::ConnectionFailed(Ptr<Socket>)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   cout << "OnOffApplication, Connection Failed" << endl;
 }
 
--- a/src/applications/udp-echo/udp-echo-client.cc	Mon Apr 14 16:39:26 2008 -0700
+++ b/src/applications/udp-echo/udp-echo-client.cc	Tue Apr 15 15:10:53 2008 -0700
@@ -63,7 +63,7 @@
 
 UdpEchoClient::UdpEchoClient ()
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   m_sent = 0;
   m_socket = 0;
   m_sendEvent = EventId ();
@@ -71,7 +71,7 @@
 
 UdpEchoClient::~UdpEchoClient()
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 }
 
 void 
@@ -84,14 +84,14 @@
 void
 UdpEchoClient::DoDispose (void)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   Application::DoDispose ();
 }
 
 void 
 UdpEchoClient::StartApplication (void)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 
   if (!m_socket)
     {
@@ -111,7 +111,7 @@
 void 
 UdpEchoClient::StopApplication ()
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 
   if (!m_socket) 
     {
@@ -125,14 +125,14 @@
 void 
 UdpEchoClient::ScheduleTransmit (Time dt)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   m_sendEvent = Simulator::Schedule(dt, &UdpEchoClient::Send, this);
 }
 
 void 
 UdpEchoClient::Send (void)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 
   NS_ASSERT (m_sendEvent.IsExpired ());
 
@@ -154,8 +154,7 @@
   Ptr<Packet> packet,
   const Address &from) 
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << socket << packet << from);
+  NS_LOG_FUNCTION (this << socket << packet << from);
 
   if (InetSocketAddress::IsMatchingType (from))
     {
--- a/src/applications/udp-echo/udp-echo-server.cc	Mon Apr 14 16:39:26 2008 -0700
+++ b/src/applications/udp-echo/udp-echo-server.cc	Tue Apr 15 15:10:53 2008 -0700
@@ -49,25 +49,25 @@
 
 UdpEchoServer::UdpEchoServer ()
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 }
 
 UdpEchoServer::~UdpEchoServer()
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 }
 
 void
 UdpEchoServer::DoDispose (void)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   Application::DoDispose ();
 }
 
 void 
 UdpEchoServer::StartApplication (void)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 
   if (!m_socket)
     {
@@ -85,7 +85,7 @@
 void 
 UdpEchoServer::StopApplication ()
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 
   if (!m_socket) 
     {
@@ -100,8 +100,7 @@
   Ptr<Packet> packet,
   const Address &from) 
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << socket << packet << from);
+  NS_LOG_FUNCTION (this << socket << packet << from);
 
   if (InetSocketAddress::IsMatchingType (from))
     {
--- a/src/common/error-model.cc	Mon Apr 14 16:39:26 2008 -0700
+++ b/src/common/error-model.cc	Tue Apr 15 15:10:53 2008 -0700
@@ -52,18 +52,18 @@
 ErrorModel::ErrorModel () :
   m_enable (true) 
 {
-  NS_LOG_FUNCTION;  
+  NS_LOG_FUNCTION_NOARGS ();
 }
 
 ErrorModel::~ErrorModel ()
 {
-  NS_LOG_FUNCTION;  
+  NS_LOG_FUNCTION_NOARGS ();
 }
 
 bool
 ErrorModel::IsCorrupt (Ptr<Packet> p)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   bool result;
   // Insert any pre-conditions here
   result = DoCorrupt (p);
@@ -74,28 +74,28 @@
 void
 ErrorModel::Reset (void)
 {
-  NS_LOG_FUNCTION;  
+  NS_LOG_FUNCTION_NOARGS ();
   DoReset ();
 }
 
 void
 ErrorModel::Enable (void)
 {
-  NS_LOG_FUNCTION;  
+  NS_LOG_FUNCTION_NOARGS ();
   m_enable = true;
 }
 
 void
 ErrorModel::Disable (void)
 {
-  NS_LOG_FUNCTION;  
+  NS_LOG_FUNCTION_NOARGS ();
   m_enable = false;
 }
 
 bool
 ErrorModel::IsEnabled (void) const
 {
-  NS_LOG_FUNCTION;  
+  NS_LOG_FUNCTION_NOARGS ();
   return m_enable;
 }
 
@@ -131,53 +131,53 @@
 
 RateErrorModel::RateErrorModel ()
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 }
 
 RateErrorModel::~RateErrorModel () 
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 }
 
 enum ErrorUnit 
 RateErrorModel::GetUnit (void) const 
 { 
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   return m_unit; 
 }
 
 void 
 RateErrorModel::SetUnit (enum ErrorUnit error_unit) 
 { 
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   m_unit = error_unit; 
 }
 
 double
 RateErrorModel::GetRate (void) const 
 { 
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   return m_rate; 
 }
 
 void 
 RateErrorModel::SetRate (double rate)
 { 
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   m_rate = rate;
 }
 
 void 
 RateErrorModel::SetRandomVariable (const RandomVariable &ranvar)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   m_ranvar = ranvar;
 }
 
 bool 
 RateErrorModel::DoCorrupt (Ptr<Packet> p) 
 { 
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   if (!m_enable)
     {
       return false;  
@@ -200,14 +200,14 @@
 bool
 RateErrorModel::DoCorruptPkt (Ptr<Packet> p)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   return (m_ranvar.GetValue () < m_rate);
 }
 
 bool
 RateErrorModel::DoCorruptByte (Ptr<Packet> p)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   // compute pkt error rate, assume uniformly distributed byte error
   double per = 1 - pow (1.0 - m_rate, p->GetSize ());
   return (m_ranvar.GetValue () < per);
@@ -216,7 +216,7 @@
 bool
 RateErrorModel::DoCorruptBit(Ptr<Packet> p)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   // compute pkt error rate, assume uniformly distributed bit error
   double per = 1 - pow (1.0 - m_rate, (8 * p->GetSize ()) );
   return (m_ranvar.GetValue () < per);
@@ -225,7 +225,7 @@
 void 
 RateErrorModel::DoReset (void) 
 { 
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   /* re-initialize any state; no-op for now */ 
 }
 
@@ -246,25 +246,25 @@
 
 ListErrorModel::ListErrorModel ()  
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 }
 
 ListErrorModel::~ListErrorModel () 
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 }
 
 std::list<uint32_t> 
 ListErrorModel::GetList (void) const 
 { 
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   return m_packetList; 
 }
 
 void 
 ListErrorModel::SetList (const std::list<uint32_t> &packetlist)
 { 
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   m_packetList = packetlist;
 }
 
@@ -274,7 +274,7 @@
 bool 
 ListErrorModel::DoCorrupt (Ptr<Packet> p) 
 { 
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   if (!m_enable)
     {
       return false;  
@@ -294,7 +294,7 @@
 void 
 ListErrorModel::DoReset (void) 
 { 
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   m_packetList.clear();
 }
 
--- a/src/common/packet-metadata.cc	Mon Apr 14 16:39:26 2008 -0700
+++ b/src/common/packet-metadata.cc	Tue Apr 15 15:10:53 2008 -0700
@@ -649,7 +649,7 @@
       m_metadataSkipped = true;
       return;
     }
-  NS_LOG_PARAMS ("uid=" << uid << "size=" << size << "");
+  NS_LOG_FUNCTION ("uid=" << uid << "size=" << size << "");
 
   struct PacketMetadata::SmallItem item;
   item.next = m_head;
@@ -670,7 +670,7 @@
       m_metadataSkipped = true;
       return;
     }
-  NS_LOG_PARAMS ("(uid=" << uid << ", size=" << size << ")");
+  NS_LOG_FUNCTION ("(uid=" << uid << ", size=" << size << ")");
   struct PacketMetadata::SmallItem item;
   struct PacketMetadata::ExtraItem extraItem;
   uint32_t read = ReadItems (m_head, &item, &extraItem);
@@ -708,7 +708,7 @@
       m_metadataSkipped = true;
       return;
     }
-  NS_LOG_PARAMS ("(uid=" << uid << ", size=" << size << ")");
+  NS_LOG_FUNCTION ("(uid=" << uid << ", size=" << size << ")");
   struct PacketMetadata::SmallItem item;
   item.next = 0xffff;
   item.prev = m_tail;
@@ -728,7 +728,7 @@
       m_metadataSkipped = true;
       return;
     }
-  NS_LOG_PARAMS ("(uid=" << uid << ", size=" << size << ")");
+  NS_LOG_FUNCTION ("(uid=" << uid << ", size=" << size << ")");
   struct PacketMetadata::SmallItem item;
   struct PacketMetadata::ExtraItem extraItem;
   uint32_t read = ReadItems (m_tail, &item, &extraItem);
--- a/src/core/log.cc	Mon Apr 14 16:39:26 2008 -0700
+++ b/src/core/log.cc	Tue Apr 15 15:10:53 2008 -0700
@@ -162,10 +162,6 @@
                     {
                       level |= LOG_FUNCTION;
                     }
-                  else if (lev == "param")
-                    {
-                      level |= LOG_PARAM;
-                    }
                   else if (lev == "logic")
                     {
                       level |= LOG_LOGIC;
@@ -202,10 +198,6 @@
                     {
                       level |= LOG_LEVEL_FUNCTION;
                     }
-                  else if (lev == "level_param")
-                    {
-                      level |= LOG_LEVEL_PARAM;
-                    }
                   else if (lev == "level_logic")
                     {
                       level |= LOG_LEVEL_LOGIC;
@@ -347,10 +339,6 @@
         {
           std::cout << "|function";
         }
-      if (i->second->IsEnabled (LOG_PARAM))
-        {
-          std::cout << "|param";
-        }
       if (i->second->IsEnabled (LOG_LOGIC))
         {
           std::cout << "|logic";
--- a/src/core/log.h	Mon Apr 14 16:39:26 2008 -0700
+++ b/src/core/log.h	Tue Apr 15 15:10:53 2008 -0700
@@ -40,20 +40,18 @@
  *
  * Use the environment variable NS_LOG to define a ':'-separated list of
  * logging components to enable. For example (using bash syntax), 
- * NS_LOG="OlsrAgent" would enable one component; 
- * NS_LOG="OlsrAgent:Ipv4L3Protocol" would enable two
- * components, etc.  NS_LOG="*" will enable all available log components at
- * all levels.
+ * NS_LOG="OlsrAgent" would enable one component at all log levels. 
+ * NS_LOG="OlsrAgent:Ipv4L3Protocol" would enable two components, 
+ * at all log levels, etc.  
+ * NS_LOG="*" will enable all available log components at all levels.
  *
- * To obtain more components than just debug log level, more components 
- * can be enabled selectively with the following
- * syntax: NS_LOG='Component1=func|param|warn:Component2=error|debug'
- * This example would enable the 'func', 'param', and 'warn' log
+ * To control more selectively the log levels for each component, use
+ * this syntax: NS_LOG='Component1=func|warn:Component2=error|debug'
+ * This example would enable the 'func', and 'warn' log
  * levels for 'Component1' and the 'error' and 'debug' log levels
  * for 'Component2'.  The wildcard can be used here as well.  For example
  * NS_LOG='*=level_all|prefix' would enable all log levels and prefix all
  * prints with the component and function names.
- *
  */
 
 /**
@@ -157,7 +155,7 @@
  *
  * Output the name of the function.
  */
-#define NS_LOG_FUNCTION                                         \
+#define NS_LOG_FUNCTION_NOARGS()                                \
   do                                                            \
     {                                                           \
       if (g_log.IsEnabled (ns3::LOG_FUNCTION))                  \
@@ -174,22 +172,22 @@
  * \ingroup logging
  * \param parameters the parameters to output.
  *
- * If log level LOG_PARAM is enabled, this macro will output
+ * If log level LOG_FUNCTION is enabled, this macro will output
  * all input parameters separated by ", ".
  *
  * Typical usage looks like:
  * \code
- * NS_LOG_PARAMS (aNumber<<anotherNumber);
+ * NS_LOG_FUNCTION (aNumber<<anotherNumber);
  * \endcode
  * And the output will look like:
  * \code
  * Component:Function (aNumber, anotherNumber)
  * \endcode
  */
-#define NS_LOG_PARAMS(parameters)                       \
+#define NS_LOG_FUNCTION(parameters)                     \
   do                                                    \
     {                                                   \
-      if (g_log.IsEnabled (ns3::LOG_PARAM))             \
+      if (g_log.IsEnabled (ns3::LOG_FUNCTION))          \
         {                                               \
           APPEND_TIME_PREFIX;                           \
           std::clog << g_log.Name () << ":"             \
@@ -243,11 +241,8 @@
   LOG_FUNCTION       = 0x00000010, // function tracing
   LOG_LEVEL_FUNCTION = 0x0000001f, 
 
-  LOG_PARAM          = 0x00000020, // parameters to functions
-  LOG_LEVEL_PARAM    = 0x0000003f,
-
-  LOG_LOGIC          = 0x00000040, // control flow tracing within functions
-  LOG_LEVEL_LOGIC    = 0x0000007f,
+  LOG_LOGIC          = 0x00000020, // control flow tracing within functions
+  LOG_LEVEL_LOGIC    = 0x0000003f,
 
   LOG_ALL            = 0x3fffffff, // print everything
   LOG_LEVEL_ALL      = LOG_ALL,
@@ -367,8 +362,8 @@
 #define NS_LOG_WARN(msg)
 #define NS_LOG_DEBUG(msg)
 #define NS_LOG_INFO(msg)
-#define NS_LOG_FUNCTION
-#define NS_LOG_PARAMS(parameters)
+#define NS_LOG_FUNCTION_NOARGS()
+#define NS_LOG_FUNCTION()
 #define NS_LOG_LOGIC(msg)
 #define NS_LOG_UNCOND(msg)
 
--- a/src/devices/csma/csma-channel.cc	Mon Apr 14 16:39:26 2008 -0700
+++ b/src/devices/csma/csma-channel.cc	Tue Apr 15 15:10:53 2008 -0700
@@ -71,7 +71,7 @@
 : 
   Channel ("Csma Channel")
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   m_state = IDLE;
   m_deviceList.clear();
 }
@@ -79,8 +79,7 @@
 int32_t
 CsmaChannel::Attach(Ptr<CsmaNetDevice> device)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << device);
+  NS_LOG_FUNCTION (this << device);
   NS_ASSERT(device != 0);
 
   CsmaDeviceRec rec(device);
@@ -92,8 +91,7 @@
 bool
 CsmaChannel::Reattach(Ptr<CsmaNetDevice> device)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << device);
+  NS_LOG_FUNCTION (this << device);
   NS_ASSERT(device != 0);
 
   std::vector<CsmaDeviceRec>::iterator it;
@@ -118,8 +116,7 @@
 bool
 CsmaChannel::Reattach(uint32_t deviceId)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << deviceId);
+  NS_LOG_FUNCTION (this << deviceId);
 
   if (deviceId < m_deviceList.size())
     {
@@ -140,8 +137,7 @@
 bool
 CsmaChannel::Detach(uint32_t deviceId)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << deviceId);
+  NS_LOG_FUNCTION (this << deviceId);
 
   if (deviceId < m_deviceList.size())
     {
@@ -171,8 +167,7 @@
 bool
 CsmaChannel::Detach(Ptr<CsmaNetDevice> device)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << device);
+  NS_LOG_FUNCTION (this << device);
   NS_ASSERT(device != 0);
 
   std::vector<CsmaDeviceRec>::iterator it;
@@ -190,8 +185,7 @@
 bool
 CsmaChannel::TransmitStart(Ptr<Packet> p, uint32_t srcId)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << p << srcId);
+  NS_LOG_FUNCTION (this << p << srcId);
   NS_LOG_INFO ("UID is " << p->GetUid () << ")");
 
   if (m_state != IDLE)
@@ -222,8 +216,7 @@
 bool
 CsmaChannel::TransmitEnd()
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << m_currentPkt << m_currentSrc);
+  NS_LOG_FUNCTION (this << m_currentPkt << m_currentSrc);
   NS_LOG_INFO ("UID is " << m_currentPkt->GetUid () << ")");
 
   NS_ASSERT(m_state == TRANSMITTING);
@@ -248,8 +241,7 @@
 void
 CsmaChannel::PropagationCompleteEvent()
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << m_currentPkt);
+  NS_LOG_FUNCTION (this << m_currentPkt);
   NS_LOG_INFO ("UID is " << m_currentPkt->GetUid () << ")");
 
   NS_ASSERT(m_state == PROPAGATING);
--- a/src/devices/csma/csma-net-device.cc	Mon Apr 14 16:39:26 2008 -0700
+++ b/src/devices/csma/csma-net-device.cc	Tue Apr 15 15:10:53 2008 -0700
@@ -88,8 +88,7 @@
     m_linkUp (false),
     m_mtu (0xffff)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this);
+  NS_LOG_FUNCTION (this);
   m_txMachineState = READY;
   m_tInterframeGap = Seconds(0);
   m_channel = 0; 
@@ -97,14 +96,14 @@
 
 CsmaNetDevice::~CsmaNetDevice()
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   m_queue = 0;
 }
 
 void 
 CsmaNetDevice::DoDispose ()
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   m_channel = 0;
   m_node = 0;
   NetDevice::DoDispose ();
@@ -119,35 +118,35 @@
 void
 CsmaNetDevice::SetSendEnable (bool sendEnable)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   m_sendEnable = sendEnable;
 }
 
 void
 CsmaNetDevice::SetReceiveEnable (bool receiveEnable)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   m_receiveEnable = receiveEnable;
 }
 
 bool
 CsmaNetDevice::IsSendEnabled (void)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   return (m_sendEnable);
 }
 
 bool
 CsmaNetDevice::IsReceiveEnabled (void)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   return (m_receiveEnable);
 }
 
 void 
 CsmaNetDevice::SetDataRate (DataRate bps)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   if (!m_channel || bps <= m_channel->GetDataRate ())
     {
       m_bps = bps;
@@ -157,7 +156,7 @@
 void 
 CsmaNetDevice::SetInterframeGap (Time t)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   m_tInterframeGap = t;
 }
 
@@ -166,7 +165,7 @@
                                  uint32_t maxSlots, uint32_t ceiling, 
                                  uint32_t maxRetries)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   m_backoff.m_slotTime = slotTime;
   m_backoff.m_minSlots = minSlots;
   m_backoff.m_maxSlots = maxSlots;
@@ -178,7 +177,7 @@
 CsmaNetDevice::AddHeader (Ptr<Packet> p, Mac48Address dest,
                             uint16_t protocolNumber)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   if (m_encapMode == RAW)
     {
       return;
@@ -217,7 +216,7 @@
 bool 
 CsmaNetDevice::ProcessHeader (Ptr<Packet> p, uint16_t & param)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   if (m_encapMode == RAW)
     {
       return true;
@@ -256,7 +255,7 @@
 void
 CsmaNetDevice::TransmitStart ()
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   NS_LOG_LOGIC ("m_currentPkt=" << m_currentPkt);
   NS_LOG_LOGIC ("UID is " << m_currentPkt->GetUid ());
 //
@@ -323,7 +322,7 @@
 void
 CsmaNetDevice::TransmitAbort (void)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   NS_LOG_LOGIC ("Pkt UID is " << m_currentPkt->GetUid () << ")");
 
   // Try to transmit a new packet
@@ -337,7 +336,7 @@
 void
 CsmaNetDevice::TransmitCompleteEvent (void)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 //
 // This function is called to finish the  process of transmitting a packet.
 // We need to tell the channel that we've stopped wiggling the wire and
@@ -363,7 +362,7 @@
 void
 CsmaNetDevice::TransmitReadyEvent (void)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 //
 // This function is called to enable the transmitter after the interframe
 // gap has passed.  If there are pending transmissions, we use this opportunity
@@ -388,8 +387,7 @@
 bool
 CsmaNetDevice::Attach (Ptr<CsmaChannel> ch)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << &ch);
+  NS_LOG_FUNCTION (this << &ch);
 
   m_channel = ch;
 
@@ -407,16 +405,14 @@
 void
 CsmaNetDevice::AddQueue (Ptr<Queue> q)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << q);
+  NS_LOG_FUNCTION (this << q);
 
   m_queue = q;
 }
 
 void CsmaNetDevice::AddReceiveErrorModel (Ptr<ErrorModel> em)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (em);
+  NS_LOG_FUNCTION (em);
   
   m_receiveErrorModel = em; 
 }
@@ -424,7 +420,7 @@
 void
 CsmaNetDevice::Receive (Ptr<Packet> packet)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 
   EthernetHeader header (false);
   EthernetTrailer trailer;
@@ -522,7 +518,7 @@
 Ptr<Queue>
 CsmaNetDevice::GetQueue(void) const 
 { 
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   return m_queue;
 }
 
@@ -610,8 +606,7 @@
 Address 
 CsmaNetDevice::MakeMulticastAddress (Ipv4Address multicastGroup) const
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << multicastGroup);
+  NS_LOG_FUNCTION (this << multicastGroup);
 //
 // First, get the generic multicast address.
 //
@@ -667,7 +662,7 @@
 bool 
 CsmaNetDevice::Send(Ptr<Packet> packet, const Address& dest, uint16_t protocolNumber)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   NS_LOG_LOGIC ("p=" << packet);
   NS_LOG_LOGIC ("UID is " << packet->GetUid () << ")");
 
--- a/src/devices/point-to-point/point-to-point-channel.cc	Mon Apr 14 16:39:26 2008 -0700
+++ b/src/devices/point-to-point/point-to-point-channel.cc	Tue Apr 15 15:10:53 2008 -0700
@@ -56,14 +56,13 @@
   Channel ("PointToPoint Channel"), 
   m_nDevices(0)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 }
 
 void
 PointToPointChannel::Attach(Ptr<PointToPointNetDevice> device)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << device);
+  NS_LOG_FUNCTION (this << device);
   NS_ASSERT(m_nDevices < N_DEVICES && "Only two devices permitted");
   NS_ASSERT(device != 0);
 
@@ -86,8 +85,7 @@
                                    Ptr<PointToPointNetDevice> src,
                                    const Time& txTime)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << p << src);
+  NS_LOG_FUNCTION (this << p << src);
   NS_LOG_LOGIC ("UID is " << p->GetUid () << ")");
 
   NS_ASSERT(m_link[0].m_state != INITIALIZING);
@@ -107,14 +105,14 @@
 uint32_t 
 PointToPointChannel::GetNDevices (void) const
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   return m_nDevices;
 }
 
 Ptr<PointToPointNetDevice>
 PointToPointChannel::GetPointToPointDevice (uint32_t i) const
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   NS_ASSERT(i < 2);
   return m_link[i].m_src;
 }
@@ -122,21 +120,21 @@
 const DataRate&
 PointToPointChannel::GetDataRate (void)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   return m_bps;
 }
 
 const Time&
 PointToPointChannel::GetDelay (void)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   return m_delay;
 }
 
 Ptr<NetDevice>
 PointToPointChannel::GetDevice (uint32_t i) const
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   return GetPointToPointDevice (i);
 }
 
--- a/src/devices/point-to-point/point-to-point-net-device.cc	Mon Apr 14 16:39:26 2008 -0700
+++ b/src/devices/point-to-point/point-to-point-net-device.cc	Tue Apr 15 15:10:53 2008 -0700
@@ -79,8 +79,7 @@
   m_linkUp (false),
   m_mtu (0xffff)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this);
+  NS_LOG_FUNCTION (this);
 }
 
 PointToPointNetDevice::~PointToPointNetDevice ()
@@ -95,7 +94,7 @@
 void 
 PointToPointNetDevice::AddHeader(Ptr<Packet> p, uint16_t protocolNumber)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   LlcSnapHeader llc;
   llc.SetType (protocolNumber);
   p->AddHeader (llc);
@@ -104,7 +103,7 @@
 bool 
 PointToPointNetDevice::ProcessHeader(Ptr<Packet> p, uint16_t& param)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   LlcSnapHeader llc;
   p->RemoveHeader (llc);
 
@@ -115,7 +114,7 @@
 
 void PointToPointNetDevice::DoDispose()
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   m_node = 0;
   m_channel = 0;
   m_receiveErrorModel = 0;
@@ -124,7 +123,7 @@
 
 void PointToPointNetDevice::SetDataRate(const DataRate& bps)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   if (!m_channel || bps <= m_channel->GetDataRate ())
     {
       m_bps = bps;
@@ -133,15 +132,14 @@
 
 void PointToPointNetDevice::SetInterframeGap(const Time& t)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   m_tInterframeGap = t;
 }
 
 bool
 PointToPointNetDevice::TransmitStart (Ptr<Packet> p)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << p);
+  NS_LOG_FUNCTION (this << p);
   NS_LOG_LOGIC ("UID is " << p->GetUid () << ")");
 //
 // This function is called to start the process of transmitting a packet.
@@ -164,7 +162,7 @@
 
 void PointToPointNetDevice::TransmitComplete (void)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 //
 // This function is called to finish the  process of transmitting a packet.
 // We need to tell the channel that we've stopped wiggling the wire and
@@ -184,8 +182,7 @@
 bool 
 PointToPointNetDevice::Attach (Ptr<PointToPointChannel> ch)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << &ch);
+  NS_LOG_FUNCTION (this << &ch);
 
   m_channel = ch;
 
@@ -211,24 +208,21 @@
 
 void PointToPointNetDevice::AddQueue (Ptr<Queue> q)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << q);
+  NS_LOG_FUNCTION (this << q);
 
   m_queue = q;
 }
 
 void PointToPointNetDevice::AddReceiveErrorModel (Ptr<ErrorModel> em)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS ("(" << em << ")");
+  NS_LOG_FUNCTION ("(" << em << ")");
 
   m_receiveErrorModel = em;
 }
 
 void PointToPointNetDevice::Receive (Ptr<Packet> packet)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << packet);
+  NS_LOG_FUNCTION (this << packet);
   uint16_t protocol = 0;
 
   if (m_receiveErrorModel && m_receiveErrorModel->IsCorrupt (packet) ) 
@@ -246,7 +240,7 @@
 
 Ptr<Queue> PointToPointNetDevice::GetQueue(void) const 
 { 
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   return m_queue;
 }
 
@@ -344,7 +338,7 @@
 bool 
 PointToPointNetDevice::Send(Ptr<Packet> packet, const Address& dest, uint16_t protocolNumber)
 {
-    NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   NS_LOG_LOGIC ("p=" << packet << ", dest=" << &dest);
   NS_LOG_LOGIC ("UID is " << packet->GetUid ());
 
--- a/src/helper/ipv4-address-helper.cc	Mon Apr 14 16:39:26 2008 -0700
+++ b/src/helper/ipv4-address-helper.cc	Tue Apr 15 15:10:53 2008 -0700
@@ -31,7 +31,7 @@
 
 Ipv4AddressHelper::Ipv4AddressHelper () 
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 
 //
 // Set the default values to an illegal state.  Do this so the client is 
@@ -52,7 +52,7 @@
   const Ipv4Mask mask,
   const Ipv4Address address)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 
   m_network = network.GetHostOrder ();
   m_mask = mask.GetHostOrder ();
@@ -114,7 +114,7 @@
   Ipv4Address
 Ipv4AddressHelper::NewNetwork (void)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   ++m_network;
   m_address = m_base;
   return Ipv4Address (m_network << m_shift);
@@ -123,7 +123,7 @@
 Ipv4InterfaceContainer
 Ipv4AddressHelper::Assign (const NetDeviceContainer &c)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   Ipv4InterfaceContainer retval;
   for (uint32_t i = 0; i < c.GetN (); ++i) {
     Ptr<NetDevice> device = c.Get (i);
@@ -156,7 +156,7 @@
   uint32_t
 Ipv4AddressHelper::NumAddressBits (uint32_t maskbits) const
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   for (uint32_t i = 0; i < N_BITS; ++i)
     {
       if (maskbits & 1)
--- a/src/internet-node/arp-ipv4-interface.cc	Mon Apr 14 16:39:26 2008 -0700
+++ b/src/internet-node/arp-ipv4-interface.cc	Tue Apr 15 15:10:53 2008 -0700
@@ -35,12 +35,12 @@
 
 ArpIpv4Interface::ArpIpv4Interface ()
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 }
 
 ArpIpv4Interface::~ArpIpv4Interface ()
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 }
 
 void 
@@ -70,8 +70,7 @@
 void 
 ArpIpv4Interface::SendTo (Ptr<Packet> p, Ipv4Address dest)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << p << dest);
+  NS_LOG_FUNCTION (this << p << dest);
 
   NS_ASSERT (GetDevice () != 0);
   if (GetDevice ()->NeedsArp ())
--- a/src/internet-node/arp-l3-protocol.cc	Mon Apr 14 16:39:26 2008 -0700
+++ b/src/internet-node/arp-l3-protocol.cc	Tue Apr 15 15:10:53 2008 -0700
@@ -47,12 +47,12 @@
 
 ArpL3Protocol::ArpL3Protocol ()
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 }
 
 ArpL3Protocol::~ArpL3Protocol ()
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 }
 
 void 
@@ -64,7 +64,7 @@
 void 
 ArpL3Protocol::DoDispose (void)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   for (CacheList::const_iterator i = m_cacheList.begin (); i != m_cacheList.end (); i++)
     {
       delete *i;
@@ -77,7 +77,7 @@
 ArpCache *
 ArpL3Protocol::FindCache (Ptr<NetDevice> device)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   for (CacheList::const_iterator i = m_cacheList.begin (); i != m_cacheList.end (); i++)
     {
       if ((*i)->GetDevice () == device)
@@ -97,7 +97,7 @@
 void 
 ArpL3Protocol::Receive(Ptr<NetDevice> device, Ptr<Packet> packet, uint16_t protocol, const Address &from)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   ArpCache *cache = FindCache (device);
   ArpHeader arp;
   packet->RemoveHeader (arp);
@@ -161,7 +161,7 @@
                        Ptr<NetDevice> device,
                        Address *hardwareDestination)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   ArpCache *cache = FindCache (device);
   ArpCache::Entry *entry = cache->Lookup (destination);
   if (entry != 0)
@@ -230,7 +230,7 @@
 void
 ArpL3Protocol::SendArpRequest (ArpCache const *cache, Ipv4Address to)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   ArpHeader arp;
   NS_LOG_LOGIC ("ARP: sending request from node "<<m_node->GetId ()<<
             " || src: " << cache->GetDevice ()->GetAddress () <<
@@ -249,7 +249,7 @@
 void
 ArpL3Protocol::SendArpReply (ArpCache const *cache, Ipv4Address toIp, Address toMac)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   ArpHeader arp;
   NS_LOG_LOGIC ("ARP: sending reply from node "<<m_node->GetId ()<<
             "|| src: " << cache->GetDevice ()->GetAddress () << 
--- a/src/internet-node/ipv4-end-point-demux.cc	Mon Apr 14 16:39:26 2008 -0700
+++ b/src/internet-node/ipv4-end-point-demux.cc	Tue Apr 15 15:10:53 2008 -0700
@@ -29,12 +29,12 @@
 Ipv4EndPointDemux::Ipv4EndPointDemux ()
   : m_ephemeral (49152)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 }
 
 Ipv4EndPointDemux::~Ipv4EndPointDemux ()
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   for (EndPointsI i = m_endPoints.begin (); i != m_endPoints.end (); i++) 
     {
       Ipv4EndPoint *endPoint = *i;
@@ -46,7 +46,7 @@
 bool
 Ipv4EndPointDemux::LookupPortLocal (uint16_t port)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   for (EndPointsI i = m_endPoints.begin (); i != m_endPoints.end (); i++) 
     {
       if ((*i)->GetLocalPort  () == port) 
@@ -60,7 +60,7 @@
 bool
 Ipv4EndPointDemux::LookupLocal (Ipv4Address addr, uint16_t port)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   for (EndPointsI i = m_endPoints.begin (); i != m_endPoints.end (); i++) 
     {
       if ((*i)->GetLocalPort () == port &&
@@ -75,7 +75,7 @@
 Ipv4EndPoint *
 Ipv4EndPointDemux::Allocate (void)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   uint16_t port = AllocateEphemeralPort ();
   if (port == 0) 
     {
@@ -91,8 +91,7 @@
 Ipv4EndPoint *
 Ipv4EndPointDemux::Allocate (Ipv4Address address)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << address);
+  NS_LOG_FUNCTION (this << address);
   uint16_t port = AllocateEphemeralPort ();
   if (port == 0) 
     {
@@ -108,8 +107,7 @@
 Ipv4EndPoint *
 Ipv4EndPointDemux::Allocate (uint16_t port)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this <<  port);
+  NS_LOG_FUNCTION (this <<  port);
 
   return Allocate (Ipv4Address::GetAny (), port);
 }
@@ -117,8 +115,7 @@
 Ipv4EndPoint *
 Ipv4EndPointDemux::Allocate (Ipv4Address address, uint16_t port)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << address << port);
+  NS_LOG_FUNCTION (this << address << port);
   if (LookupLocal (address, port)) 
     {
       NS_LOG_WARN ("Duplicate address/port; failing.");
@@ -134,8 +131,7 @@
 Ipv4EndPointDemux::Allocate (Ipv4Address localAddress, uint16_t localPort,
 			     Ipv4Address peerAddress, uint16_t peerPort)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << localAddress << localPort << peerAddress << peerPort);
+  NS_LOG_FUNCTION (this << localAddress << localPort << peerAddress << peerPort);
   for (EndPointsI i = m_endPoints.begin (); i != m_endPoints.end (); i++) 
     {
       if ((*i)->GetLocalPort () == localPort &&
@@ -160,7 +156,7 @@
 void 
 Ipv4EndPointDemux::DeAllocate (Ipv4EndPoint *endPoint)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   for (EndPointsI i = m_endPoints.begin (); i != m_endPoints.end (); i++) 
     {
       if (*i == endPoint)
@@ -182,13 +178,13 @@
                            Ipv4Address saddr, uint16_t sport,
                            Ptr<Ipv4Interface> incomingInterface)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   EndPoints retval1; // Matches exact on local port, wildcards on others
   EndPoints retval2; // Matches exact on local port/adder, wildcards on others
   EndPoints retval3; // Matches all but local address
   EndPoints retval4; // Exact match on all 4
   
-  NS_LOG_PARAMS (this << daddr << dport << saddr << sport << incomingInterface);
+  NS_LOG_FUNCTION (this << daddr << dport << saddr << sport << incomingInterface);
   NS_LOG_DEBUG ("Looking up endpoint for destination address " << daddr);
   for (EndPointsI i = m_endPoints.begin (); i != m_endPoints.end (); i++) 
     {
@@ -276,7 +272,7 @@
 uint16_t
 Ipv4EndPointDemux::AllocateEphemeralPort (void)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   uint16_t port = m_ephemeral;
   do 
     {
--- a/src/internet-node/ipv4-interface.cc	Mon Apr 14 16:39:26 2008 -0700
+++ b/src/internet-node/ipv4-interface.cc	Tue Apr 15 15:10:53 2008 -0700
@@ -38,42 +38,39 @@
   : m_ifup(false),
     m_metric(1)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this);
+  NS_LOG_FUNCTION (this);
 }
 
 Ipv4Interface::~Ipv4Interface ()
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 }
 
 void
 Ipv4Interface::DoDispose (void)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   Object::DoDispose ();
 }
 
 void 
 Ipv4Interface::SetAddress (Ipv4Address a)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << a);
+  NS_LOG_FUNCTION (this << a);
   m_address = a;
 }
 
 void 
 Ipv4Interface::SetNetworkMask (Ipv4Mask mask)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << mask);
+  NS_LOG_FUNCTION (this << mask);
   m_netmask = mask;
 }
 
 Ipv4Address
 Ipv4Interface::GetBroadcast (void) const
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   uint32_t mask = m_netmask.GetHostOrder ();
   uint32_t address = m_address.GetHostOrder ();
   Ipv4Address broadcast = Ipv4Address (address | (~mask));
@@ -83,36 +80,35 @@
 Ipv4Mask 
 Ipv4Interface::GetNetworkMask (void) const
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   return m_netmask;
 }
 
 void
 Ipv4Interface::SetMetric (uint16_t metric)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (metric);
+  NS_LOG_FUNCTION (metric);
   m_metric = metric;
 }
 
 uint16_t
 Ipv4Interface::GetMetric (void) const
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   return m_metric;
 }
 
 Ipv4Address 
 Ipv4Interface::GetAddress (void) const
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   return m_address;
 }
 
 uint16_t 
 Ipv4Interface::GetMtu (void) const
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   if (GetDevice () == 0)
     {
       uint32_t mtu = (1<<16) - 1;
@@ -129,28 +125,28 @@
 bool 
 Ipv4Interface::IsUp (void) const
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   return m_ifup;
 }
 
 bool 
 Ipv4Interface::IsDown (void) const
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   return !m_ifup;
 }
 
 void 
 Ipv4Interface::SetUp (void)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   m_ifup = true;
 }
 
 void 
 Ipv4Interface::SetDown (void)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   m_ifup = false;
 }
 
@@ -158,7 +154,7 @@
 void 
 Ipv4Interface::Send(Ptr<Packet> p, Ipv4Address dest)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   if (IsUp()) {
     NS_LOG_LOGIC ("SendTo");
     SendTo(p, dest);
--- a/src/internet-node/ipv4-l3-protocol.cc	Mon Apr 14 16:39:26 2008 -0700
+++ b/src/internet-node/ipv4-l3-protocol.cc	Tue Apr 15 15:10:53 2008 -0700
@@ -73,14 +73,14 @@
   : m_nInterfaces (0),
     m_identification (0)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   m_staticRouting = CreateObject<Ipv4StaticRouting> ();
   AddRoutingProtocol (m_staticRouting, 0);
 }
 
 Ipv4L3Protocol::~Ipv4L3Protocol ()
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 }
 
 void
@@ -93,7 +93,7 @@
 void 
 Ipv4L3Protocol::DoDispose (void)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   m_interfaces.clear ();
   m_node = 0;
   m_staticRouting->Dispose ();
@@ -104,7 +104,7 @@
 void
 Ipv4L3Protocol::SetupLoopback (void)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 
   Ptr<Ipv4LoopbackInterface> interface = CreateObject<Ipv4LoopbackInterface> ();
   interface->SetNode (m_node);
@@ -118,7 +118,7 @@
 void 
 Ipv4L3Protocol::SetDefaultTtl (uint8_t ttl)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   m_defaultTtl = ttl;
 }
     
@@ -128,8 +128,7 @@
                       Ipv4Address nextHop, 
                       uint32_t interface)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << dest << nextHop << interface);
+  NS_LOG_FUNCTION (this << dest << nextHop << interface);
   m_staticRouting->AddHostRouteTo (dest, nextHop, interface);
 }
 
@@ -137,8 +136,7 @@
 Ipv4L3Protocol::AddHostRouteTo (Ipv4Address dest, 
 				uint32_t interface)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << dest << interface);
+  NS_LOG_FUNCTION (this << dest << interface);
   m_staticRouting->AddHostRouteTo (dest, interface);
 }
 
@@ -148,8 +146,7 @@
 				   Ipv4Address nextHop, 
 				   uint32_t interface)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << network << networkMask << nextHop << interface);
+  NS_LOG_FUNCTION (this << network << networkMask << nextHop << interface);
   m_staticRouting->AddNetworkRouteTo (network, networkMask, nextHop, interface);
 }
 
@@ -158,8 +155,7 @@
 				   Ipv4Mask networkMask, 
 				   uint32_t interface)
 {
-  NS_LOG_FUNCTION; 
-  NS_LOG_PARAMS (this << network << networkMask << interface);
+  NS_LOG_FUNCTION (this << network << networkMask << interface);
   m_staticRouting->AddNetworkRouteTo (network, networkMask, interface);
 }
 
@@ -167,8 +163,7 @@
 Ipv4L3Protocol::SetDefaultRoute (Ipv4Address nextHop, 
 				 uint32_t interface)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << nextHop << interface);
+  NS_LOG_FUNCTION (this << nextHop << interface);
   m_staticRouting->SetDefaultRoute (nextHop, interface);
 }
 
@@ -178,8 +173,7 @@
   Ptr<Packet> packet,
   Ipv4RoutingProtocol::RouteReplyCallback routeReply)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << &ipHeader << packet << &routeReply);
+  NS_LOG_FUNCTION (this << &ipHeader << packet << &routeReply);
 
   Lookup (Ipv4RoutingProtocol::IF_INDEX_ANY, ipHeader, packet, routeReply);
 }
@@ -191,8 +185,7 @@
   Ptr<Packet> packet,
   Ipv4RoutingProtocol::RouteReplyCallback routeReply)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << ifIndex << &ipHeader << packet << &routeReply);
+  NS_LOG_FUNCTION (this << ifIndex << &ipHeader << packet << &routeReply);
 
   for (Ipv4RoutingProtocolList::const_iterator rprotoIter = 
          m_routingProtocols.begin ();
@@ -240,8 +233,7 @@
 Ipv4L3Protocol::AddRoutingProtocol (Ptr<Ipv4RoutingProtocol> routingProtocol,
                                     int priority)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << &routingProtocol << priority);
+  NS_LOG_FUNCTION (this << &routingProtocol << priority);
   m_routingProtocols.push_back
     (std::pair<int, Ptr<Ipv4RoutingProtocol> > (-priority, routingProtocol));
   m_routingProtocols.sort ();
@@ -250,22 +242,21 @@
 uint32_t 
 Ipv4L3Protocol::GetNRoutes (void)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   return m_staticRouting->GetNRoutes ();
 }
 
 Ipv4Route *
 Ipv4L3Protocol::GetRoute (uint32_t index)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   return m_staticRouting->GetRoute (index);
 }
 
 void 
 Ipv4L3Protocol::RemoveRoute (uint32_t index)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << index);
+  NS_LOG_FUNCTION (this << index);
   m_staticRouting->RemoveRoute (index);
 }
 
@@ -275,8 +266,7 @@
                                    uint32_t inputInterface,
                                    std::vector<uint32_t> outputInterfaces)
 {
-  NS_LOG_FUNCTION; 
-  NS_LOG_PARAMS (this << origin << group << inputInterface << &outputInterfaces);
+  NS_LOG_FUNCTION (this << origin << group << inputInterface << &outputInterfaces);
 
   m_staticRouting->AddMulticastRoute (origin, group, inputInterface,
     outputInterfaces);
@@ -285,8 +275,7 @@
 void 
 Ipv4L3Protocol::SetDefaultMulticastRoute (uint32_t outputInterface)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << outputInterface);
+  NS_LOG_FUNCTION (this << outputInterface);
 
   m_staticRouting->SetDefaultMulticastRoute (outputInterface);
 }
@@ -294,15 +283,14 @@
 uint32_t 
 Ipv4L3Protocol::GetNMulticastRoutes (void) const
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   return m_staticRouting->GetNMulticastRoutes ();
 }
 
 Ipv4MulticastRoute *
 Ipv4L3Protocol::GetMulticastRoute (uint32_t index) const
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << index);
+  NS_LOG_FUNCTION (this << index);
   return m_staticRouting->GetMulticastRoute (index);
 }
 
@@ -311,24 +299,21 @@
                                        Ipv4Address group,
                                        uint32_t inputInterface)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << origin << group << inputInterface);
+  NS_LOG_FUNCTION (this << origin << group << inputInterface);
   m_staticRouting->RemoveMulticastRoute (origin, group, inputInterface);
 }
 
 void 
 Ipv4L3Protocol::RemoveMulticastRoute (uint32_t index)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << index);
+  NS_LOG_FUNCTION (this << index);
   m_staticRouting->RemoveMulticastRoute (index);
 }
 
 uint32_t 
 Ipv4L3Protocol::AddInterface (Ptr<NetDevice> device)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << &device);
+  NS_LOG_FUNCTION (this << &device);
   Ptr<ArpIpv4Interface> interface = CreateObject<ArpIpv4Interface> ();
   interface->SetNode (m_node);
   interface->SetDevice (device);
@@ -338,8 +323,7 @@
 uint32_t 
 Ipv4L3Protocol::AddIpv4Interface (Ptr<Ipv4Interface>interface)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << interface);
+  NS_LOG_FUNCTION (this << interface);
   uint32_t index = m_nInterfaces;
   m_interfaces.push_back (interface);
   m_nInterfaces++;
@@ -349,8 +333,7 @@
 Ptr<Ipv4Interface>
 Ipv4L3Protocol::GetInterface (uint32_t index) const
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << index);
+  NS_LOG_FUNCTION (this << index);
   uint32_t tmp = 0;
   for (Ipv4InterfaceList::const_iterator i = m_interfaces.begin (); i != m_interfaces.end (); i++)
     {
@@ -366,15 +349,14 @@
 uint32_t 
 Ipv4L3Protocol::GetNInterfaces (void) const
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   return m_nInterfaces;
 }
 
 uint32_t 
 Ipv4L3Protocol::FindInterfaceForAddr (Ipv4Address addr) const
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << addr);
+  NS_LOG_FUNCTION (this << addr);
 
   uint32_t ifIndex = 0;
   for (Ipv4InterfaceList::const_iterator i = m_interfaces.begin (); 
@@ -395,8 +377,7 @@
 uint32_t 
 Ipv4L3Protocol::FindInterfaceForAddr (Ipv4Address addr, Ipv4Mask mask) const
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << addr << mask);
+  NS_LOG_FUNCTION (this << addr << mask);
 
   uint32_t ifIndex = 0;
   for (Ipv4InterfaceList::const_iterator i = m_interfaces.begin (); 
@@ -417,8 +398,7 @@
 int32_t 
 Ipv4L3Protocol::FindInterfaceIndexForDevice (Ptr<NetDevice> device) const
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << device);
+  NS_LOG_FUNCTION (this << device);
 
   uint32_t ifIndex = 0;
   for (Ipv4InterfaceList::const_iterator i = m_interfaces.begin (); 
@@ -437,8 +417,7 @@
 Ptr<Ipv4Interface>
 Ipv4L3Protocol::FindInterfaceForDevice (Ptr<const NetDevice> device)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << &device);
+  NS_LOG_FUNCTION (this << &device);
   for (Ipv4InterfaceList::const_iterator i = m_interfaces.begin (); i != m_interfaces.end (); i++)
     {
       if ((*i)->GetDevice () == device)
@@ -452,8 +431,7 @@
 void 
 Ipv4L3Protocol::Receive( Ptr<NetDevice> device, Ptr<Packet> packet, uint16_t protocol, const Address &from)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << &device << packet << protocol <<  from);
+  NS_LOG_FUNCTION (this << &device << packet << protocol <<  from);
 
   NS_LOG_LOGIC ("Packet from " << from << " received on node " << m_node->GetId ());
 
@@ -494,8 +472,7 @@
             Ipv4Address destination,
             uint8_t protocol)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << packet << source << destination << protocol);
+  NS_LOG_FUNCTION (this << packet << source << destination << protocol);
 
   Ipv4Header ipHeader;
 
@@ -545,8 +522,7 @@
                              Ptr<Packet> packet,
                              Ipv4Header const &ipHeader)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << found << &route << packet << &ipHeader);
+  NS_LOG_FUNCTION (this << found << &route << packet << &ipHeader);
 
   packet->AddHeader (ipHeader);
   if (!found)
@@ -580,8 +556,7 @@
   Ipv4Header &ipHeader, 
   Ptr<NetDevice> device)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (ifIndex << packet << &ipHeader<< device);
+  NS_LOG_FUNCTION (ifIndex << packet << &ipHeader<< device);
   NS_LOG_LOGIC ("Forwarding logic for node: " << m_node->GetId ());
 
   for (Ipv4InterfaceList::const_iterator i = m_interfaces.begin ();
@@ -661,8 +636,7 @@
 Ipv4L3Protocol::ForwardUp (Ptr<Packet> p, Ipv4Header const&ip,
                            Ptr<Ipv4Interface> incomingInterface)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << p << &ip);
+  NS_LOG_FUNCTION (this << p << &ip);
 
   Ptr<Ipv4L4Demux> demux = m_node->GetObject<Ipv4L4Demux> ();
   Ptr<Ipv4L4Protocol> protocol = demux->GetProtocol (ip.GetProtocol ());
@@ -672,8 +646,7 @@
 void 
 Ipv4L3Protocol::JoinMulticastGroup (Ipv4Address origin, Ipv4Address group)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << origin << group);
+  NS_LOG_FUNCTION (this << origin << group);
   m_multicastGroups.push_back(
     std::pair<Ipv4Address, Ipv4Address> (origin, group));
 }
@@ -681,8 +654,7 @@
 void
 Ipv4L3Protocol::LeaveMulticastGroup (Ipv4Address origin, Ipv4Address group)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << origin << group);
+  NS_LOG_FUNCTION (this << origin << group);
 
   for (Ipv4MulticastGroupList::iterator i = m_multicastGroups.begin ();
        i != m_multicastGroups.end (); 
@@ -699,8 +671,7 @@
 void 
 Ipv4L3Protocol::SetAddress (uint32_t i, Ipv4Address address)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << i << address);
+  NS_LOG_FUNCTION (this << i << address);
   Ptr<Ipv4Interface> interface = GetInterface (i);
   interface->SetAddress (address);
 }
@@ -708,8 +679,7 @@
 void 
 Ipv4L3Protocol::SetNetworkMask (uint32_t i, Ipv4Mask mask)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << i << mask);
+  NS_LOG_FUNCTION (this << i << mask);
   Ptr<Ipv4Interface> interface = GetInterface (i);
   interface->SetNetworkMask (mask);
 }
@@ -717,8 +687,7 @@
 Ipv4Mask 
 Ipv4L3Protocol::GetNetworkMask (uint32_t i) const
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << i);
+  NS_LOG_FUNCTION (this << i);
   Ptr<Ipv4Interface> interface = GetInterface (i);
   return interface->GetNetworkMask ();
 }
@@ -726,8 +695,7 @@
 Ipv4Address 
 Ipv4L3Protocol::GetAddress (uint32_t i) const
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << i);
+  NS_LOG_FUNCTION (this << i);
   Ptr<Ipv4Interface> interface = GetInterface (i);
   return interface->GetAddress ();
 }
@@ -735,8 +703,7 @@
 void 
 Ipv4L3Protocol::SetMetric (uint32_t i, uint16_t metric)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (i << metric);
+  NS_LOG_FUNCTION (i << metric);
   Ptr<Ipv4Interface> interface = GetInterface (i);
   interface->SetMetric (metric);
 }
@@ -744,8 +711,7 @@
 uint16_t
 Ipv4L3Protocol::GetMetric (uint32_t i) const
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (i);
+  NS_LOG_FUNCTION (i);
   Ptr<Ipv4Interface> interface = GetInterface (i);
   return interface->GetMetric ();
 }
@@ -754,8 +720,7 @@
 Ipv4L3Protocol::GetIfIndexForDestination (
   Ipv4Address destination, uint32_t& ifIndex) const
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << destination << &ifIndex);
+  NS_LOG_FUNCTION (this << destination << &ifIndex);
 //
 // The first thing we do in trying to determine a source address is to 
 // consult the routing protocols.  These will also check for a default route
@@ -824,8 +789,7 @@
 uint16_t 
 Ipv4L3Protocol::GetMtu (uint32_t i) const
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << i);
+  NS_LOG_FUNCTION (this << i);
   Ptr<Ipv4Interface> interface = GetInterface (i);
   return interface->GetMtu ();
 }
@@ -833,8 +797,7 @@
 bool 
 Ipv4L3Protocol::IsUp (uint32_t i) const
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << i);
+  NS_LOG_FUNCTION (this << i);
   Ptr<Ipv4Interface> interface = GetInterface (i);
   return interface->IsUp ();
 }
@@ -842,8 +805,7 @@
 void 
 Ipv4L3Protocol::SetUp (uint32_t i)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << i);
+  NS_LOG_FUNCTION (this << i);
   Ptr<Ipv4Interface> interface = GetInterface (i);
   interface->SetUp ();
 
@@ -861,8 +823,7 @@
 void 
 Ipv4L3Protocol::SetDown (uint32_t ifaceIndex)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << ifaceIndex);
+  NS_LOG_FUNCTION (this << ifaceIndex);
   Ptr<Ipv4Interface> interface = GetInterface (ifaceIndex);
   interface->SetDown ();
 
--- a/src/internet-node/ipv4-loopback-interface.cc	Mon Apr 14 16:39:26 2008 -0700
+++ b/src/internet-node/ipv4-loopback-interface.cc	Tue Apr 15 15:10:53 2008 -0700
@@ -34,12 +34,12 @@
 Ipv4LoopbackInterface::Ipv4LoopbackInterface ()
   : m_node (0)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 }
 
 Ipv4LoopbackInterface::~Ipv4LoopbackInterface ()
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   NS_ASSERT (m_node != 0);
 }
 
@@ -58,8 +58,7 @@
 void 
 Ipv4LoopbackInterface::SendTo (Ptr<Packet> packet, Ipv4Address dest)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << packet << dest);
+  NS_LOG_FUNCTION (this << packet << dest);
 
   Ptr<Ipv4L3Protocol> ipv4 = 
     m_node->GetObject<Ipv4L3Protocol> ();
--- a/src/internet-node/ipv4-static-routing.cc	Mon Apr 14 16:39:26 2008 -0700
+++ b/src/internet-node/ipv4-static-routing.cc	Tue Apr 15 15:10:53 2008 -0700
@@ -29,7 +29,7 @@
 Ipv4StaticRouting::Ipv4StaticRouting () 
 : m_defaultRoute (0), m_defaultMulticastRoute (0)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 }
 
 void 
@@ -37,7 +37,7 @@
                                    Ipv4Address nextHop, 
                                    uint32_t interface)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   Ipv4Route *route = new Ipv4Route ();
   *route = Ipv4Route::CreateHostRouteTo (dest, nextHop, interface);
   m_hostRoutes.push_back (route);
@@ -47,7 +47,7 @@
 Ipv4StaticRouting::AddHostRouteTo (Ipv4Address dest, 
                                    uint32_t interface)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   Ipv4Route *route = new Ipv4Route ();
   *route = Ipv4Route::CreateHostRouteTo (dest, interface);
   m_hostRoutes.push_back (route);
@@ -59,7 +59,7 @@
                                       Ipv4Address nextHop, 
                                       uint32_t interface)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   Ipv4Route *route = new Ipv4Route ();
   *route = Ipv4Route::CreateNetworkRouteTo (network,
                                             networkMask,
@@ -73,7 +73,7 @@
                                       Ipv4Mask networkMask, 
                                       uint32_t interface)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   Ipv4Route *route = new Ipv4Route ();
   *route = Ipv4Route::CreateNetworkRouteTo (network,
                                             networkMask,
@@ -85,7 +85,7 @@
 Ipv4StaticRouting::SetDefaultRoute (Ipv4Address nextHop, 
                                     uint32_t interface)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   Ipv4Route *route = new Ipv4Route ();
   *route = Ipv4Route::CreateDefaultRoute (nextHop, interface);
   delete m_defaultRoute;
@@ -98,7 +98,7 @@
                                      uint32_t inputInterface,
                                      std::vector<uint32_t> outputInterfaces)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   Ipv4MulticastRoute *route = new Ipv4MulticastRoute ();
   *route = Ipv4MulticastRoute::CreateMulticastRoute (origin, group, 
     inputInterface, outputInterfaces);
@@ -108,7 +108,7 @@
 void 
 Ipv4StaticRouting::SetDefaultMulticastRoute(uint32_t outputInterface)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   Ipv4Address origin = Ipv4Address::GetAny ();
   Ipv4Address group = Ipv4Address::GetAny ();
   uint32_t inputInterface = Ipv4RoutingProtocol::IF_INDEX_ANY;
@@ -127,14 +127,14 @@
 uint32_t 
 Ipv4StaticRouting::GetNMulticastRoutes (void) const
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   return m_multicastRoutes.size () + m_defaultMulticastRoute ? 1 : 0;
 }
 
 Ipv4MulticastRoute *
 Ipv4StaticRouting::GetMulticastRoute (uint32_t index) const
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   NS_ASSERT_MSG(index < m_multicastRoutes.size (),
     "Ipv4StaticRouting::GetMulticastRoute ():  Index out of range");
 //
@@ -182,7 +182,7 @@
 Ipv4MulticastRoute *
 Ipv4StaticRouting::GetDefaultMulticastRoute () const
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   if (m_defaultMulticastRoute != 0)
     {
       return m_defaultMulticastRoute;
@@ -195,7 +195,7 @@
                                         Ipv4Address group,
                                         uint32_t inputInterface)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   for (MulticastRoutesI i = m_multicastRoutes.begin (); 
        i != m_multicastRoutes.end (); 
        i++) 
@@ -216,7 +216,7 @@
 void 
 Ipv4StaticRouting::RemoveMulticastRoute(uint32_t index)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 //
 // From an external point of view the default route appears to be in slot 0
 // of the routing table.  The implementation, however, puts it in a separate 
@@ -261,7 +261,7 @@
 Ipv4Route *
 Ipv4StaticRouting::LookupStatic (Ipv4Address dest)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   for (HostRoutesCI i = m_hostRoutes.begin (); 
        i != m_hostRoutes.end (); 
        i++) 
@@ -298,7 +298,7 @@
   Ipv4Address group,
   uint32_t    ifIndex)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 //
 // We treat the "any" address (typically 0.0.0.0) as a wildcard in our matching
 // scheme.
@@ -400,7 +400,7 @@
 uint32_t 
 Ipv4StaticRouting::GetNRoutes (void)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   uint32_t n = 0;
   if (m_defaultRoute != 0)
     {
@@ -414,7 +414,7 @@
 Ipv4Route *
 Ipv4StaticRouting::GetDefaultRoute ()
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   if (m_defaultRoute != 0)
     {
       return m_defaultRoute;
@@ -428,7 +428,7 @@
 Ipv4Route *
 Ipv4StaticRouting::GetRoute (uint32_t index)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   if (index == 0 && m_defaultRoute != 0)
     {
       return m_defaultRoute;
@@ -470,7 +470,7 @@
 void 
 Ipv4StaticRouting::RemoveRoute (uint32_t index)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   if (index == 0 && m_defaultRoute != 0)
     {
       delete m_defaultRoute;
@@ -520,8 +520,7 @@
   Ptr<Packet> packet,
   RouteReplyCallback routeReply)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << ifIndex << &ipHeader << packet << &routeReply);
+  NS_LOG_FUNCTION (this << ifIndex << &ipHeader << packet << &routeReply);
 
   NS_LOG_LOGIC ("source = " << ipHeader.GetSource ());
 
@@ -573,8 +572,7 @@
 bool
 Ipv4StaticRouting::RequestIfIndex (Ipv4Address destination, uint32_t& ifIndex)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << destination << &ifIndex);
+  NS_LOG_FUNCTION (this << destination << &ifIndex);
 //
 // First, see if this is a multicast packet we have a route for.  If we
 // have a route, then send the packet down each of the specified interfaces.
@@ -621,7 +619,7 @@
 void
 Ipv4StaticRouting::DoDispose (void)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   for (HostRoutesI i = m_hostRoutes.begin (); 
        i != m_hostRoutes.end (); 
        i = m_hostRoutes.erase (i)) 
--- a/src/internet-node/tcp-l4-protocol.cc	Mon Apr 14 16:39:26 2008 -0700
+++ b/src/internet-node/tcp-l4-protocol.cc	Tue Apr 15 15:10:53 2008 -0700
@@ -49,7 +49,7 @@
   : aT (LAST_STATE, StateActionVec_t(LAST_EVENT)),
        eV (MAX_FLAGS)
 { 
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 
   // Create the state table
   // Closed state
@@ -290,15 +290,13 @@
 
 SA TcpStateMachine::Lookup (States_t s, Events_t e)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << s << e);
+  NS_LOG_FUNCTION (this << s << e);
   return aT[s][e];
 }
 
 Events_t TcpStateMachine::FlagsEvent (uint8_t f)
 { 
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << f);
+  NS_LOG_FUNCTION (this << f);
   // Lookup event from flags
   if (f >= MAX_FLAGS) return BAD_FLAGS;
   return eV[f]; // Look up flags event
@@ -337,13 +335,13 @@
 TcpL4Protocol::TcpL4Protocol ()
   : m_endPoints (new Ipv4EndPointDemux ())
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   NS_LOG_LOGIC("Made a TcpL4Protocol "<<this);
 }
 
 TcpL4Protocol::~TcpL4Protocol ()
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 }
 
 void 
@@ -366,7 +364,7 @@
 void
 TcpL4Protocol::DoDispose (void)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   if (m_endPoints != 0)
     {
       delete m_endPoints;
@@ -379,7 +377,7 @@
 Ptr<Socket>
 TcpL4Protocol::CreateSocket (void)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   Ptr<RttEstimator> rtt = m_rttFactory.Create<RttEstimator> ();
   Ptr<TcpSocket> socket = CreateObject<TcpSocket> ();
   socket->SetNode (m_node);
@@ -391,31 +389,28 @@
 Ipv4EndPoint *
 TcpL4Protocol::Allocate (void)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   return m_endPoints->Allocate ();
 }
 
 Ipv4EndPoint *
 TcpL4Protocol::Allocate (Ipv4Address address)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << address);
+  NS_LOG_FUNCTION (this << address);
   return m_endPoints->Allocate (address);
 }
 
 Ipv4EndPoint *
 TcpL4Protocol::Allocate (uint16_t port)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << port);
+  NS_LOG_FUNCTION (this << port);
   return m_endPoints->Allocate (port);
 }
 
 Ipv4EndPoint *
 TcpL4Protocol::Allocate (Ipv4Address address, uint16_t port)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << address << port);
+  NS_LOG_FUNCTION (this << address << port);
   return m_endPoints->Allocate (address, port);
 }
 
@@ -423,8 +418,7 @@
 TcpL4Protocol::Allocate (Ipv4Address localAddress, uint16_t localPort,
                          Ipv4Address peerAddress, uint16_t peerPort)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << localAddress << localPort << peerAddress << peerPort);
+  NS_LOG_FUNCTION (this << localAddress << localPort << peerAddress << peerPort);
   return m_endPoints->Allocate (localAddress, localPort,
                                 peerAddress, peerPort);
 }
@@ -432,8 +426,7 @@
 void 
 TcpL4Protocol::DeAllocate (Ipv4EndPoint *endPoint)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << endPoint);
+  NS_LOG_FUNCTION (this << endPoint);
   m_endPoints->DeAllocate (endPoint);
 }
 
@@ -443,8 +436,7 @@
              Ipv4Address const &destination,
              Ptr<Ipv4Interface> incomingInterface)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << packet << source << destination << incomingInterface);
+  NS_LOG_FUNCTION (this << packet << source << destination << incomingInterface);
 
   TcpHeader tcpHeader;
   //these two do a peek, so that the packet can be forwarded up
@@ -481,8 +473,7 @@
            Ipv4Address saddr, Ipv4Address daddr, 
            uint16_t sport, uint16_t dport)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << packet << saddr << daddr << sport << dport);
+  NS_LOG_FUNCTION (this << packet << saddr << daddr << sport << dport);
 
   TcpHeader tcpHeader;
   tcpHeader.SetDestinationPort (dport);
@@ -512,8 +503,7 @@
               << " ack " << outgoingHeader.GetAckNumber()
               << " flags " << std::hex << (int)outgoingHeader.GetFlags() << std::dec
               << " data size " << packet->GetSize());
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << packet << saddr << daddr);
+  NS_LOG_FUNCTION (this << packet << saddr << daddr);
   // XXX outgoingHeader cannot be logged
 
   outgoingHeader.SetLength (5); //header length in units of 32bit words
--- a/src/internet-node/tcp-socket.cc	Mon Apr 14 16:39:26 2008 -0700
+++ b/src/internet-node/tcp-socket.cc	Tue Apr 15 15:10:53 2008 -0700
@@ -80,8 +80,7 @@
     m_rtt (0),
     m_lastMeasuredRtt (Seconds(0.0))
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this);
+  NS_LOG_FUNCTION (this);
   
 }
 
@@ -125,7 +124,7 @@
     m_cnTimeout (sock.m_cnTimeout),
     m_cnCount (sock.m_cnCount)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   NS_LOG_LOGIC("Invoked the copy constructor");
   //copy the pending data if necessary
   if(sock.m_pendingData)
@@ -143,8 +142,7 @@
 
 TcpSocket::~TcpSocket ()
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS(this);
+  NS_LOG_FUNCTION(this);
   m_node = 0;
   if (m_endPoint != 0)
     {
@@ -198,21 +196,21 @@
 enum Socket::SocketErrno
 TcpSocket::GetErrno (void) const
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   return m_errno;
 }
 
 Ptr<Node>
 TcpSocket::GetNode (void) const
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   return m_node;
 }
 
 void 
 TcpSocket::Destroy (void)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   m_node = 0;
   m_endPoint = 0;
   m_tcp = 0;
@@ -221,7 +219,7 @@
 int
 TcpSocket::FinishBind (void)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   if (m_endPoint == 0)
     {
       return -1;
@@ -236,15 +234,14 @@
 int
 TcpSocket::Bind (void)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   m_endPoint = m_tcp->Allocate ();
   return FinishBind ();
 }
 int 
 TcpSocket::Bind (const Address &address)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this<<address);
+  NS_LOG_FUNCTION (this<<address);
   if (!InetSocketAddress::IsMatchingType (address))
     {
       return ERROR_INVAL;
@@ -279,14 +276,14 @@
 int 
 TcpSocket::ShutdownSend (void)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   m_shutdownSend = true;
   return 0;
 }
 int 
 TcpSocket::ShutdownRecv (void)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   m_shutdownRecv = false;
   return 0;
 }
@@ -294,7 +291,7 @@
 int
 TcpSocket::Close (void)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   if (m_state == CLOSED) 
     {
       return -1;
@@ -316,8 +313,7 @@
 int
 TcpSocket::Connect (const Address & address)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << address);
+  NS_LOG_FUNCTION (this << address);
   if (m_endPoint == 0)
     {
       if (Bind () == -1)
@@ -360,8 +356,7 @@
 
 int TcpSocket::Send (const uint8_t* buf, uint32_t size)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << buf << size);
+  NS_LOG_FUNCTION (this << buf << size);
   if (m_state == ESTABLISHED || m_state == SYN_SENT || m_state == CLOSE_WAIT)
     { // Ok to buffer some data to send
       if (!m_pendingData)
@@ -390,8 +385,7 @@
 
 int TcpSocket::DoSendTo (Ptr<Packet> p, const Address &address)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << p << address);
+  NS_LOG_FUNCTION (this << p << address);
   InetSocketAddress transport = InetSocketAddress::ConvertFrom (address);
   Ipv4Address ipv4 = transport.GetIpv4 ();
   uint16_t port = transport.GetPort ();
@@ -400,8 +394,7 @@
 
 int TcpSocket::DoSendTo (Ptr<Packet> p, Ipv4Address ipv4, uint16_t port)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << p << ipv4 << port);
+  NS_LOG_FUNCTION (this << p << ipv4 << port);
   if (m_endPoint == 0)
     {
       if (Bind () == -1)
@@ -425,8 +418,7 @@
 int 
 TcpSocket::SendTo (const Address &address, Ptr<Packet> p)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << address << p);
+  NS_LOG_FUNCTION (this << address << p);
   if (!m_connected)
     {
       m_errno = ERROR_NOTCONN;
@@ -441,8 +433,7 @@
 int
 TcpSocket::Listen (uint32_t q)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << q);
+  NS_LOG_FUNCTION (this << q);
   Actions_t action = ProcessEvent (APP_LISTEN);
   ProcessAction (action);
   return 0;
@@ -457,8 +448,7 @@
                " sport " << m_endPoint->GetPeerPort() <<
                " saddr " << m_endPoint->GetPeerAddress());
 
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << packet << ipv4 << port);
+  NS_LOG_FUNCTION (this << packet << ipv4 << port);
   if (m_shutdownRecv)
     {
       return;
@@ -486,8 +476,7 @@
 
 Actions_t TcpSocket::ProcessEvent (Events_t e)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << e);
+  NS_LOG_FUNCTION (this << e);
   States_t saveState = m_state;
   NS_LOG_LOGIC ("TcpSocket " << this << " processing event " << e);
   // simulation singleton is a way to get a single global static instance of a
@@ -538,8 +527,7 @@
 
 void TcpSocket::SendEmptyPacket (uint8_t flags)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << flags);
+  NS_LOG_FUNCTION (this << flags);
   Ptr<Packet> p = Create<Packet> ();
   TcpHeader header;
 
@@ -569,8 +557,7 @@
 
 bool TcpSocket::ProcessAction (Actions_t a)
 { // These actions do not require a packet or any TCP Headers
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << a);
+  NS_LOG_FUNCTION (this << a);
   switch (a)
   {
     case NO_ACT:
@@ -648,8 +635,7 @@
                                      const TcpHeader& tcpHeader,
                                      const Address& fromAddress)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << a << p  << fromAddress);
+  NS_LOG_FUNCTION (this << a << p  << fromAddress);
   uint32_t localIfIndex;
   Ptr<Ipv4> ipv4 = m_node->GetObject<Ipv4> ();
   switch (a)
@@ -813,8 +799,7 @@
 
 bool TcpSocket::SendPendingData (bool withAck)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << withAck);
+  NS_LOG_FUNCTION (this << withAck);
   NS_LOG_LOGIC ("ENTERING SendPendingData");
   if (!m_pendingData)
     {
@@ -900,26 +885,26 @@
 
 uint32_t  TcpSocket::UnAckDataCount ()
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   return m_nextTxSequence - m_highestRxAck;
 }
 
 uint32_t  TcpSocket::BytesInFlight ()
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   return m_highTxMark - m_highestRxAck;
 }
 
 uint32_t  TcpSocket::Window ()
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   NS_LOG_LOGIC ("TcpSocket::Window() "<<this);
   return std::min (m_rxWindowSize, m_cWnd.Get());
 }
 
 uint32_t  TcpSocket::AvailableWindow ()
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   uint32_t unack = UnAckDataCount (); // Number of outstanding bytes
   uint32_t win = Window ();
   if (win < unack) 
@@ -933,8 +918,7 @@
                         const TcpHeader& tcpHeader, 
                         const Address& fromAddress)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << p << "tcpHeader " << fromAddress);
+  NS_LOG_FUNCTION (this << p << "tcpHeader " << fromAddress);
   NS_LOG_LOGIC ("TcpSocket " << this << " NewRx,"
                 << " seq " << tcpHeader.GetSequenceNumber()
                 << " ack " << tcpHeader.GetAckNumber()
@@ -1077,8 +1061,7 @@
 { // CommonNewAck is called only for "New" (non-duplicate) acks
   // and MUST be called by any subclass, from the NewAck function
   // Always cancel any pending re-tx timer on new acknowledgement
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << ack << skipTimer); 
+  NS_LOG_FUNCTION (this << ack << skipTimer); 
   //DEBUG(1,(cout << "TCP " << this << "Cancelling retx timer " << endl));
   if (!skipTimer)
     {
@@ -1121,8 +1104,7 @@
 void TcpSocket::NewAck (SequenceNumber seq)
 { // New acknowledgement up to sequence number "seq"
   // Adjust congestion window in response to new ack's received
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << seq);
+  NS_LOG_FUNCTION (this << seq);
   NS_LOG_LOGIC ("TcpSocket " << this << " NewAck "
            << " seq " << seq
            << " cWnd " << m_cWnd
@@ -1149,8 +1131,7 @@
 
 void TcpSocket::DupAck (const TcpHeader& t, uint32_t count)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << "t " << count);
+  NS_LOG_FUNCTION (this << "t " << count);
   NS_LOG_LOGIC ("TcpSocket " << this << " DupAck " <<  t.GetAckNumber ()
       << ", count " << count
       << ", time " << Simulator::Now ());
@@ -1172,8 +1153,7 @@
 
 void TcpSocket::ReTxTimeout ()
 { // Retransmit timeout
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this);
+  NS_LOG_FUNCTION (this);
   m_ssThresh = Window () / 2; // Per RFC2581
   m_ssThresh = std::max (m_ssThresh, 2 * m_segmentSize);
   // Set cWnd to segSize on timeout,  per rfc2581
@@ -1200,8 +1180,7 @@
 
 void TcpSocket::Retransmit ()
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this);
+  NS_LOG_FUNCTION (this);
   uint8_t flags = TcpHeader::NONE;
   if (m_state == SYN_SENT) 
     {
--- a/src/internet-node/udp-l4-protocol.cc	Mon Apr 14 16:39:26 2008 -0700
+++ b/src/internet-node/udp-l4-protocol.cc	Tue Apr 15 15:10:53 2008 -0700
@@ -52,12 +52,12 @@
 UdpL4Protocol::UdpL4Protocol ()
   : m_endPoints (new Ipv4EndPointDemux ())
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 }
 
 UdpL4Protocol::~UdpL4Protocol ()
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 }
 
 void 
@@ -81,7 +81,7 @@
 void
 UdpL4Protocol::DoDispose (void)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   if (m_endPoints != 0)
     {
       delete m_endPoints;
@@ -94,7 +94,7 @@
 Ptr<Socket>
 UdpL4Protocol::CreateSocket (void)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   Ptr<UdpSocket> socket = CreateObject<UdpSocket> ();
   socket->SetNode (m_node);
   socket->SetUdp (this);
@@ -104,39 +104,35 @@
 Ipv4EndPoint *
 UdpL4Protocol::Allocate (void)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   return m_endPoints->Allocate ();
 }
 
 Ipv4EndPoint *
 UdpL4Protocol::Allocate (Ipv4Address address)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << address);
+  NS_LOG_FUNCTION (this << address);
   return m_endPoints->Allocate (address);
 }
 
 Ipv4EndPoint *
 UdpL4Protocol::Allocate (uint16_t port)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << port);
+  NS_LOG_FUNCTION (this << port);
   return m_endPoints->Allocate (port);
 }
 
 Ipv4EndPoint *
 UdpL4Protocol::Allocate (Ipv4Address address, uint16_t port)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << address << port);
+  NS_LOG_FUNCTION (this << address << port);
   return m_endPoints->Allocate (address, port);
 }
 Ipv4EndPoint *
 UdpL4Protocol::Allocate (Ipv4Address localAddress, uint16_t localPort,
                          Ipv4Address peerAddress, uint16_t peerPort)
 {
-  NS_LOG_FUNCTION; 
-  NS_LOG_PARAMS (this << localAddress << localPort << peerAddress << peerPort);
+  NS_LOG_FUNCTION (this << localAddress << localPort << peerAddress << peerPort);
   return m_endPoints->Allocate (localAddress, localPort,
                                 peerAddress, peerPort);
 }
@@ -144,8 +140,7 @@
 void 
 UdpL4Protocol::DeAllocate (Ipv4EndPoint *endPoint)
 {
-  NS_LOG_FUNCTION; 
-  NS_LOG_PARAMS (this << endPoint);
+  NS_LOG_FUNCTION (this << endPoint);
   m_endPoints->DeAllocate (endPoint);
 }
 
@@ -155,8 +150,7 @@
                        Ipv4Address const &destination,
                        Ptr<Ipv4Interface> interface)
 {
-  NS_LOG_FUNCTION; 
-  NS_LOG_PARAMS (this << packet << source << destination);
+  NS_LOG_FUNCTION (this << packet << source << destination);
 
   UdpHeader udpHeader;
   packet->RemoveHeader (udpHeader);
@@ -175,8 +169,7 @@
                      Ipv4Address saddr, Ipv4Address daddr, 
                      uint16_t sport, uint16_t dport)
 {
-  NS_LOG_FUNCTION; 
-  NS_LOG_PARAMS (this << packet << saddr << daddr << sport << dport);
+  NS_LOG_FUNCTION (this << packet << saddr << daddr << sport << dport);
 
   UdpHeader udpHeader;
   udpHeader.SetDestination (dport);
--- a/src/internet-node/udp-socket.cc	Mon Apr 14 16:39:26 2008 -0700
+++ b/src/internet-node/udp-socket.cc	Tue Apr 15 15:10:53 2008 -0700
@@ -42,12 +42,12 @@
     m_shutdownRecv (false),
     m_connected (false)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 }
 
 UdpSocket::~UdpSocket ()
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 
   m_node = 0;
   if (m_endPoint != 0)
@@ -83,21 +83,21 @@
 enum Socket::SocketErrno
 UdpSocket::GetErrno (void) const
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   return m_errno;
 }
 
 Ptr<Node>
 UdpSocket::GetNode (void) const
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   return m_node;
 }
 
 void 
 UdpSocket::Destroy (void)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   m_node = 0;
   m_endPoint = 0;
   m_udp = 0;
@@ -106,7 +106,7 @@
 int
 UdpSocket::FinishBind (void)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   if (m_endPoint == 0)
     {
       return -1;
@@ -119,7 +119,7 @@
 int
 UdpSocket::Bind (void)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   m_endPoint = m_udp->Allocate ();
   return FinishBind ();
 }
@@ -127,8 +127,7 @@
 int 
 UdpSocket::Bind (const Address &address)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << address);
+  NS_LOG_FUNCTION (this << address);
 
   if (!InetSocketAddress::IsMatchingType (address))
     {
@@ -161,7 +160,7 @@
 int 
 UdpSocket::ShutdownSend (void)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   m_shutdownSend = true;
   return 0;
 }
@@ -169,7 +168,7 @@
 int 
 UdpSocket::ShutdownRecv (void)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   m_shutdownRecv = false;
   return 0;
 }
@@ -177,7 +176,7 @@
 int
 UdpSocket::Close(void)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   NotifyCloseCompleted ();
   return 0;
 }
@@ -185,8 +184,7 @@
 int
 UdpSocket::Connect(const Address & address)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << address);
+  NS_LOG_FUNCTION (this << address);
   Ipv4Route routeToDest;
   InetSocketAddress transport = InetSocketAddress::ConvertFrom (address);
   m_defaultAddress = transport.GetIpv4 ();
@@ -200,8 +198,7 @@
 int 
 UdpSocket::Send (Ptr<Packet> p)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << p);
+  NS_LOG_FUNCTION (this << p);
 
   if (!m_connected)
     {
@@ -214,7 +211,7 @@
 int 
 UdpSocket::DoSend (Ptr<Packet> p)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   if (m_endPoint == 0)
     {
       if (Bind () == -1)
@@ -236,8 +233,7 @@
 int
 UdpSocket::DoSendTo (Ptr<Packet> p, const Address &address)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << p << address);
+  NS_LOG_FUNCTION (this << p << address);
 
   if (!m_connected)
     {
@@ -258,8 +254,7 @@
 int
 UdpSocket::DoSendTo (Ptr<Packet> p, Ipv4Address dest, uint16_t port)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << p << dest << port);
+  NS_LOG_FUNCTION (this << p << dest << port);
 
   Ipv4Route routeToDest;
 
@@ -322,8 +317,7 @@
 int 
 UdpSocket::SendTo(const Address &address, Ptr<Packet> p)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << address << p);
+  NS_LOG_FUNCTION (this << address << p);
   InetSocketAddress transport = InetSocketAddress::ConvertFrom (address);
   Ipv4Address ipv4 = transport.GetIpv4 ();
   uint16_t port = transport.GetPort ();
@@ -333,8 +327,7 @@
 void 
 UdpSocket::ForwardUp (Ptr<Packet> packet, Ipv4Address ipv4, uint16_t port)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << packet << ipv4 << port);
+  NS_LOG_FUNCTION (this << packet << ipv4 << port);
 
   if (m_shutdownRecv)
     {
--- a/src/mobility/random-direction-2d-mobility-model.cc	Mon Apr 14 16:39:26 2008 -0700
+++ b/src/mobility/random-direction-2d-mobility-model.cc	Tue Apr 15 15:10:53 2008 -0700
@@ -85,7 +85,7 @@
 void
 RandomDirection2dMobilityModel::SetDirectionAndSpeed (double direction)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   double speed = m_speed.GetValue ();
   const Vector vector (std::cos (direction) * speed,
                        std::sin (direction) * speed,
--- a/src/node/channel.cc	Mon Apr 14 16:39:26 2008 -0700
+++ b/src/node/channel.cc	Tue Apr 15 15:10:53 2008 -0700
@@ -37,33 +37,31 @@
 Channel::Channel ()
   : m_name("Channel")
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 }
 
 Channel::Channel (std::string name)
   : m_name(name)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << name);
+  NS_LOG_FUNCTION (this << name);
 }
 
 Channel::~Channel ()
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 }
 
   void
 Channel::SetName(std::string name)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << name);
+  NS_LOG_FUNCTION (this << name);
   m_name = name;
 }
 
   std::string
 Channel::GetName(void)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   return m_name;
 }
 
--- a/src/node/drop-tail-queue.cc	Mon Apr 14 16:39:26 2008 -0700
+++ b/src/node/drop-tail-queue.cc	Tue Apr 15 15:10:53 2008 -0700
@@ -44,19 +44,18 @@
   Queue (),
   m_packets ()
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 }
 
 DropTailQueue::~DropTailQueue ()
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 }
 
 bool 
 DropTailQueue::DoEnqueue (Ptr<Packet> p)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << p);
+  NS_LOG_FUNCTION (this << p);
 
   if (m_packets.size () >= m_maxPackets)
     {
@@ -72,8 +71,7 @@
 Ptr<Packet>
 DropTailQueue::DoDequeue (void)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this);
+  NS_LOG_FUNCTION (this);
 
   if (m_packets.empty()) 
     {
@@ -92,8 +90,7 @@
 Ptr<Packet>
 DropTailQueue::DoPeek (void) const
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this);
+  NS_LOG_FUNCTION (this);
 
   if (m_packets.empty()) 
     {
--- a/src/node/ipv4-address-generator.cc	Mon Apr 14 16:39:26 2008 -0700
+++ b/src/node/ipv4-address-generator.cc	Tue Apr 15 15:10:53 2008 -0700
@@ -78,14 +78,14 @@
 Ipv4AddressGeneratorImpl::Ipv4AddressGeneratorImpl () 
   : m_entries (), m_test (false)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   Reset ();
 }
 
   void
 Ipv4AddressGeneratorImpl::Reset (void)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 
   uint32_t mask = 0;
 //
@@ -123,7 +123,7 @@
 
 Ipv4AddressGeneratorImpl::~Ipv4AddressGeneratorImpl ()
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 }
 
   void
@@ -132,7 +132,7 @@
   const Ipv4Mask mask,
   const Ipv4Address addr)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 //
 // We're going to be playing with the actual bits in the network and mask so
 // pull them out into ints.
@@ -170,7 +170,7 @@
 Ipv4AddressGeneratorImpl::GetNetwork (
   const Ipv4Mask mask) const
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 
   uint32_t index = MaskToIndex (mask);
   return Ipv4Address (m_netTable[index].network << m_netTable[index].shift);
@@ -180,7 +180,7 @@
 Ipv4AddressGeneratorImpl::NextNetwork (
   const Ipv4Mask mask)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 //
 // The way this is expected to be used is that an address and network prefix
 // are initialized, and then NextAddress() is called repeatedly to set the
@@ -200,7 +200,7 @@
   const Ipv4Address addr,
   const Ipv4Mask mask)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 
   uint32_t index = MaskToIndex (mask);
   uint32_t addrBits = addr.GetHostOrder ();
@@ -215,7 +215,7 @@
 Ipv4AddressGeneratorImpl::GetAddress (
   const Ipv4Mask mask) const
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 
   uint32_t index = MaskToIndex (mask);
 
@@ -227,7 +227,7 @@
   Ipv4Address
 Ipv4AddressGeneratorImpl::NextAddress (const Ipv4Mask mask)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 //
 // The way this is expected to be used is that an address and network prefix
 // are initialized, and then NextAddress() is called repeatedly to set the
@@ -256,7 +256,7 @@
   bool
 Ipv4AddressGeneratorImpl::AddAllocated (const Ipv4Address address)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 
   uint32_t addr = address.GetHostOrder ();
 
@@ -347,7 +347,7 @@
   void
 Ipv4AddressGeneratorImpl::TestMode (void)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   m_test = true;
 }
 
@@ -390,7 +390,7 @@
   const Ipv4Mask mask,
   const Ipv4Address addr)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 
   SimulationSingleton<Ipv4AddressGeneratorImpl>::Get ()
     ->Init (net, mask, addr);
@@ -399,7 +399,7 @@
   Ipv4Address
 Ipv4AddressGenerator::NextNetwork (const Ipv4Mask mask)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 
   return SimulationSingleton<Ipv4AddressGeneratorImpl>::Get ()
     ->NextNetwork (mask);
@@ -408,7 +408,7 @@
   Ipv4Address
 Ipv4AddressGenerator::GetNetwork (const Ipv4Mask mask)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 
   return SimulationSingleton<Ipv4AddressGeneratorImpl>::Get ()
     ->GetNetwork (mask);
@@ -419,7 +419,7 @@
   const Ipv4Address addr,
   const Ipv4Mask mask)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 
   SimulationSingleton<Ipv4AddressGeneratorImpl>::Get ()
     ->InitAddress (addr, mask);
@@ -428,7 +428,7 @@
   Ipv4Address
 Ipv4AddressGenerator::GetAddress (const Ipv4Mask mask)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 
   return SimulationSingleton<Ipv4AddressGeneratorImpl>::Get ()
     ->GetAddress (mask);
@@ -437,7 +437,7 @@
   Ipv4Address
 Ipv4AddressGenerator::NextAddress (const Ipv4Mask mask)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 
   return SimulationSingleton<Ipv4AddressGeneratorImpl>::Get ()
     ->NextAddress (mask);
@@ -446,7 +446,7 @@
   void
 Ipv4AddressGenerator::Reset (void)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 
   return SimulationSingleton<Ipv4AddressGeneratorImpl>::Get ()
     ->Reset ();
@@ -455,7 +455,7 @@
   bool
 Ipv4AddressGenerator::AddAllocated (const Ipv4Address addr)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 
   return SimulationSingleton<Ipv4AddressGeneratorImpl>::Get ()
     ->AddAllocated (addr);
@@ -464,7 +464,7 @@
   void
   Ipv4AddressGenerator::TestMode (void)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 
   SimulationSingleton<Ipv4AddressGeneratorImpl>::Get ()
     ->TestMode ();
--- a/src/node/node-list.cc	Mon Apr 14 16:39:26 2008 -0700
+++ b/src/node/node-list.cc	Tue Apr 15 15:10:53 2008 -0700
@@ -88,7 +88,7 @@
 void 
 NodeListPriv::Delete (void)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   Config::UnregisterRootNamespaceObject (Get ());
   (*DoGet ()) = 0;
 }
@@ -96,11 +96,11 @@
 
 NodeListPriv::NodeListPriv ()
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 }
 NodeListPriv::~NodeListPriv ()
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   for (std::vector<Ptr<Node> >::iterator i = m_nodes.begin ();
        i != m_nodes.end (); i++)
     {
--- a/src/node/packet-socket.cc	Mon Apr 14 16:39:26 2008 -0700
+++ b/src/node/packet-socket.cc	Tue Apr 15 15:10:53 2008 -0700
@@ -31,8 +31,7 @@
 
 PacketSocket::PacketSocket ()
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   m_state = STATE_OPEN;
   m_shutdownSend = false;
   m_shutdownRecv = false;
@@ -47,34 +46,34 @@
 
 PacketSocket::~PacketSocket ()
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 }
 
 void 
 PacketSocket::DoDispose (void)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   m_device = 0;
 }
 
 enum Socket::SocketErrno
 PacketSocket::GetErrno (void) const
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   return m_errno;
 }
 
 Ptr<Node>
 PacketSocket::GetNode (void) const
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   return m_node;
 }
 
 int
 PacketSocket::Bind (void)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   PacketSocketAddress address;
   address.SetProtocol (0);
   address.SetAllDevices ();
@@ -84,7 +83,7 @@
 int
 PacketSocket::Bind (const Address &address)
 { 
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   if (!PacketSocketAddress::IsMatchingType (address))
     {
       m_errno = ERROR_INVAL;
@@ -97,7 +96,7 @@
 int
 PacketSocket::DoBind (const PacketSocketAddress &address)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   if (m_state == STATE_BOUND ||
       m_state == STATE_CONNECTED)
     {
@@ -130,7 +129,7 @@
 int
 PacketSocket::ShutdownSend (void)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   if (m_state == STATE_CLOSED)
     {
       m_errno = ERROR_BADF;
@@ -143,7 +142,7 @@
 int
 PacketSocket::ShutdownRecv (void)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   if (m_state == STATE_CLOSED)
     {
       m_errno = ERROR_BADF;
@@ -156,7 +155,7 @@
 int
 PacketSocket::Close(void)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   if (m_state == STATE_CLOSED)
     {
       m_errno = ERROR_BADF;
@@ -170,7 +169,7 @@
 int
 PacketSocket::Connect(const Address &ad)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   PacketSocketAddress address;
   if (m_state == STATE_CLOSED)
     {
@@ -205,7 +204,7 @@
 int
 PacketSocket::Send (Ptr<Packet> p)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   if (m_state == STATE_OPEN ||
       m_state == STATE_BOUND)
     {
@@ -218,7 +217,7 @@
 int
 PacketSocket::SendTo(const Address &address, Ptr<Packet> p)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   PacketSocketAddress ad;
   if (m_state == STATE_CLOSED)
     {
@@ -291,7 +290,7 @@
 PacketSocket::ForwardUp (Ptr<NetDevice> device, Ptr<Packet> packet, 
                          uint16_t protocol, const Address &from)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   if (m_shutdownRecv)
     {
       return;
--- a/src/node/queue.cc	Mon Apr 14 16:39:26 2008 -0700
+++ b/src/node/queue.cc	Tue Apr 15 15:10:53 2008 -0700
@@ -49,20 +49,19 @@
   m_nTotalDroppedBytes(0),
   m_nTotalDroppedPackets(0)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 }
 
 Queue::~Queue()
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 }
 
 
 bool 
 Queue::Enqueue (Ptr<Packet> p)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << p);
+  NS_LOG_FUNCTION (this << p);
   NS_LOG_LOGIC ("m_traceEnqueue (p)");
 
   m_traceEnqueue (p);
@@ -79,8 +78,7 @@
 Ptr<Packet>
 Queue::Dequeue (void)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this);
+  NS_LOG_FUNCTION (this);
 
   Ptr<Packet> packet = DoDequeue ();
 
@@ -102,15 +100,14 @@
 void
 Queue::DequeueAll (void)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   NS_ASSERT_MSG (0, "Don't know what to do with dequeued packets!");
 }
 
 Ptr<Packet>
 Queue::Peek (void) const
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this);
+  NS_LOG_FUNCTION (this);
   return DoPeek ();
 }
 
@@ -118,7 +115,7 @@
 uint32_t 
 Queue::GetNPackets (void) const
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   NS_LOG_LOGIC ("returns " << m_nPackets);
   return m_nPackets;
 }
@@ -126,7 +123,7 @@
 uint32_t
 Queue::GetNBytes (void) const
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   NS_LOG_LOGIC (" returns " << m_nBytes);
   return m_nBytes;
 }
@@ -134,7 +131,7 @@
 bool
 Queue::IsEmpty (void) const
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   NS_LOG_LOGIC ("returns " << (m_nPackets == 0));
   return m_nPackets == 0;
 }
@@ -142,7 +139,7 @@
 uint32_t
 Queue::GetTotalReceivedBytes (void) const
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   NS_LOG_LOGIC("returns " << m_nTotalReceivedBytes);
   return m_nTotalReceivedBytes;
 }
@@ -150,7 +147,7 @@
 uint32_t
 Queue::GetTotalReceivedPackets (void) const
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   NS_LOG_LOGIC ("returns " << m_nTotalReceivedPackets);
   return m_nTotalReceivedPackets;
 }
@@ -158,7 +155,7 @@
 uint32_t
 Queue:: GetTotalDroppedBytes (void) const
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   NS_LOG_LOGIC ("returns " << m_nTotalDroppedBytes);
   return m_nTotalDroppedBytes;
 }
@@ -166,7 +163,7 @@
 uint32_t
 Queue::GetTotalDroppedPackets (void) const
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   NS_LOG_LOGIC("returns " << m_nTotalDroppedPackets);
   return m_nTotalDroppedPackets;
 }
@@ -174,7 +171,7 @@
 void 
 Queue::ResetStatistics (void)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   m_nTotalReceivedBytes = 0;
   m_nTotalReceivedPackets = 0;
   m_nTotalDroppedBytes = 0;
@@ -184,8 +181,7 @@
 void
 Queue::Drop (Ptr<Packet> p)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << p);
+  NS_LOG_FUNCTION (this << p);
 
   m_nTotalDroppedPackets++;
   m_nTotalDroppedBytes += p->GetSize ();
--- a/src/node/socket.cc	Mon Apr 14 16:39:26 2008 -0700
+++ b/src/node/socket.cc	Tue Apr 15 15:10:53 2008 -0700
@@ -30,13 +30,13 @@
 
 Socket::~Socket ()
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 }
 
 void 
 Socket::SetCloseCallback (Callback<void,Ptr<Socket> > closeCompleted)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   m_closeCompleted = closeCompleted;
 }
 
@@ -46,7 +46,7 @@
   Callback<void, Ptr<Socket> > connectionFailed,
   Callback<void, Ptr<Socket> > halfClose)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   m_connectionSucceeded = connectionSucceeded;
   m_connectionFailed = connectionFailed;
   m_halfClose = halfClose;
@@ -58,7 +58,7 @@
   Callback<void, Ptr<Socket>, const Address&> newConnectionCreated,
   Callback<void, Ptr<Socket> > closeRequested)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   m_connectionRequest = connectionRequest;
   m_newConnectionCreated = newConnectionCreated;
   m_closeRequested = closeRequested;
@@ -67,20 +67,20 @@
 void 
 Socket::SetSendCallback (Callback<void, Ptr<Socket>, uint32_t> dataSent)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   m_dataSent = dataSent;
 }
 
 void 
 Socket::SetRecvCallback (Callback<void, Ptr<Socket>, Ptr<Packet>,const Address&> receivedData)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   m_receivedData = receivedData;
 }
 
 int Socket::Send (const uint8_t* buf, uint32_t size)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   Ptr<Packet> p;
   if (buf)
     {
@@ -95,7 +95,7 @@
 
 int Socket::SendTo (const Address &address, const uint8_t* buf, uint32_t size)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   Ptr<Packet> p;
   if(buf)
     {
@@ -117,7 +117,7 @@
 void 
 Socket::NotifyCloseCompleted (void)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   if (!m_closeCompleted.IsNull ())
     {
       m_closeCompleted (this);
@@ -127,7 +127,7 @@
 void 
 Socket::NotifyConnectionSucceeded (void)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   if (!m_connectionSucceeded.IsNull ())
     {
       m_connectionSucceeded (this);
@@ -137,7 +137,7 @@
 void 
 Socket::NotifyConnectionFailed (void)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   if (!m_connectionFailed.IsNull ())
     {
       m_connectionFailed (this);
@@ -147,7 +147,7 @@
 void 
 Socket::NotifyHalfClose (void)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   if (!m_halfClose.IsNull ())
     {
       m_halfClose (this);
@@ -157,7 +157,7 @@
 bool 
 Socket::NotifyConnectionRequest (const Address &from)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   if (!m_connectionRequest.IsNull ())
     {
       return m_connectionRequest (this, from);
@@ -175,7 +175,7 @@
 void 
 Socket::NotifyNewConnectionCreated (Ptr<Socket> socket, const Address &from)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   if (!m_newConnectionCreated.IsNull ())
     {
       m_newConnectionCreated (socket, from);
@@ -185,7 +185,7 @@
 void 
 Socket::NotifyCloseRequested (void)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   if (!m_closeRequested.IsNull ())
     {
       m_closeRequested (this);
@@ -195,7 +195,7 @@
 void 
 Socket::NotifyDataSent (uint32_t size)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   if (!m_dataSent.IsNull ())
     {
       m_dataSent (this, size);
@@ -205,7 +205,7 @@
 void 
 Socket::NotifyDataReceived (Ptr<Packet> p, const Address &from)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   if (!m_receivedData.IsNull ())
     {
       m_receivedData (this, p, from);
--- a/src/routing/global-routing/candidate-queue.cc	Mon Apr 14 16:39:26 2008 -0700
+++ b/src/routing/global-routing/candidate-queue.cc	Tue Apr 15 15:10:53 2008 -0700
@@ -28,19 +28,19 @@
 CandidateQueue::CandidateQueue()
   : m_candidates ()
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 }
 
 CandidateQueue::~CandidateQueue()
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   Clear ();
 }
 
   void
 CandidateQueue::Clear (void)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   while (!m_candidates.empty ())
     {
       SPFVertex *p = Pop ();
@@ -52,8 +52,7 @@
   void
 CandidateQueue::Push (SPFVertex *vNew)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << vNew);
+  NS_LOG_FUNCTION (this << vNew);
 
   CandidateList_t::iterator i = m_candidates.begin ();  
 
@@ -71,7 +70,7 @@
   SPFVertex *
 CandidateQueue::Pop (void)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   if (m_candidates.empty ())
     {
       return 0;
@@ -85,7 +84,7 @@
   SPFVertex *
 CandidateQueue::Top (void) const
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   if (m_candidates.empty ())
     {
       return 0;
@@ -97,21 +96,21 @@
   bool
 CandidateQueue::Empty (void) const
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   return m_candidates.empty ();
 }
 
   uint32_t
 CandidateQueue::Size (void) const
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   return m_candidates.size ();
 }
 
   SPFVertex *
 CandidateQueue::Find (const Ipv4Address addr) const
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   CandidateList_t::const_iterator i = m_candidates.begin ();
 
   for (; i != m_candidates.end (); i++)
@@ -129,7 +128,7 @@
   void
 CandidateQueue::Reorder (void)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   std::list<SPFVertex*> temp;
 
   while (!m_candidates.empty ()) {
--- a/src/routing/global-routing/global-route-manager-impl.cc	Mon Apr 14 16:39:26 2008 -0700
+++ b/src/routing/global-routing/global-route-manager-impl.cc	Tue Apr 15 15:10:53 2008 -0700
@@ -54,7 +54,7 @@
   m_parent (0),
   m_children ()
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 }
 
 SPFVertex::SPFVertex (GlobalRoutingLSA* lsa) : 
@@ -66,7 +66,7 @@
   m_parent (0),
   m_children ()
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   if (lsa->GetLSType () == GlobalRoutingLSA::RouterLSA) 
     {
       NS_LOG_LOGIC ("Setting m_vertexType to VertexRouter");
@@ -81,7 +81,7 @@
 
 SPFVertex::~SPFVertex ()
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   for ( ListOfSPFVertex_t::iterator i = m_children.begin ();
         i != m_children.end ();
         i++)
@@ -97,112 +97,112 @@
   void 
 SPFVertex::SetVertexType (SPFVertex::VertexType type)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   m_vertexType = type;
 }
 
   SPFVertex::VertexType 
 SPFVertex::GetVertexType (void) const
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   return m_vertexType;
 }
 
   void 
 SPFVertex::SetVertexId (Ipv4Address id)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   m_vertexId = id;
 }
 
   Ipv4Address
 SPFVertex::GetVertexId (void) const
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   return m_vertexId;
 }
 
   void 
 SPFVertex::SetLSA (GlobalRoutingLSA* lsa)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   m_lsa = lsa;
 }
 
   GlobalRoutingLSA* 
 SPFVertex::GetLSA (void) const
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   return m_lsa;
 }
 
   void 
 SPFVertex::SetDistanceFromRoot (uint32_t distance)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   m_distanceFromRoot = distance;
 }
 
   uint32_t
 SPFVertex::GetDistanceFromRoot (void) const
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   return m_distanceFromRoot;
 }
 
   void 
 SPFVertex::SetOutgoingTypeId (uint32_t id)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   m_rootOif = id;
 }
 
   uint32_t 
 SPFVertex::GetOutgoingTypeId (void) const
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   return m_rootOif;
 }
 
   void 
 SPFVertex::SetNextHop (Ipv4Address nextHop)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   m_nextHop = nextHop;
 }
 
   Ipv4Address
 SPFVertex::GetNextHop (void) const
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   return m_nextHop;
 }
 
   void
 SPFVertex::SetParent (SPFVertex* parent)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   m_parent = parent;
 }
 
   SPFVertex* 
 SPFVertex::GetParent (void) const
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   return m_parent;
 }
 
   uint32_t 
 SPFVertex::GetNChildren (void) const
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   return m_children.size ();
 }
 
   SPFVertex* 
 SPFVertex::GetChild (uint32_t n) const
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   uint32_t j = 0;
 
   for ( ListOfSPFVertex_t::const_iterator i = m_children.begin ();
@@ -221,7 +221,7 @@
   uint32_t 
 SPFVertex::AddChild (SPFVertex* child)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   m_children.push_back (child);
   return m_children.size ();
 }
@@ -236,12 +236,12 @@
 :
   m_database ()
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 }
 
 GlobalRouteManagerLSDB::~GlobalRouteManagerLSDB ()
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   LSDBMap_t::iterator i;
   for (i= m_database.begin (); i!= m_database.end (); i++)
     {
@@ -256,7 +256,7 @@
   void
 GlobalRouteManagerLSDB::Initialize ()
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   LSDBMap_t::iterator i;
   for (i= m_database.begin (); i!= m_database.end (); i++)
     {
@@ -268,14 +268,14 @@
   void
 GlobalRouteManagerLSDB::Insert (Ipv4Address addr, GlobalRoutingLSA* lsa)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   m_database.insert (LSDBPair_t (addr, lsa));
 }
 
   GlobalRoutingLSA*
 GlobalRouteManagerLSDB::GetLSA (Ipv4Address addr) const
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 //
 // Look up an LSA by its address.
 //
@@ -293,7 +293,7 @@
   GlobalRoutingLSA*
 GlobalRouteManagerLSDB::GetLSAByLinkData (Ipv4Address addr) const
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 //
 // Look up an LSA by its address.
 //
@@ -325,13 +325,13 @@
 : 
   m_spfroot (0) 
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   m_lsdb = new GlobalRouteManagerLSDB ();
 }
 
 GlobalRouteManagerImpl::~GlobalRouteManagerImpl ()
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   if (m_lsdb)
     {
       delete m_lsdb;
@@ -341,7 +341,7 @@
   void
 GlobalRouteManagerImpl::DebugUseLsdb (GlobalRouteManagerLSDB* lsdb)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   if (m_lsdb)
     {
       delete m_lsdb;
@@ -359,7 +359,7 @@
   void
 GlobalRouteManagerImpl::SelectRouterNodes () 
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   for (NodeList::Iterator i = NodeList::Begin (); i != NodeList::End (); i++)
     {
       Ptr<Node> node = *i;
@@ -383,7 +383,7 @@
   void
 GlobalRouteManagerImpl::BuildGlobalRoutingDatabase () 
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 //
 // Walk the list of nodes looking for the GlobalRouter Interface.
 //
@@ -464,7 +464,7 @@
   void
 GlobalRouteManagerImpl::InitializeRoutes ()
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 //
 // Walk the list of nodes in the system.
 //
@@ -504,7 +504,7 @@
   void
 GlobalRouteManagerImpl::SPFNext (SPFVertex* v, CandidateQueue& candidate)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 
   SPFVertex* w = 0;
   GlobalRoutingLSA* w_lsa = 0;
@@ -706,7 +706,7 @@
   GlobalRoutingLinkRecord* l,
   uint32_t distance)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 //
 // If w is a NetworkVertex, l should be null
 /*
@@ -891,7 +891,7 @@
   SPFVertex* w,
   GlobalRoutingLinkRecord* prev_link) 
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 
   bool skip = true;
   bool found_prev_link = false;
@@ -966,7 +966,7 @@
   void
 GlobalRouteManagerImpl::DebugSPFCalculate (Ipv4Address root)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   SPFCalculate (root);
 }
 
@@ -974,8 +974,7 @@
   void
 GlobalRouteManagerImpl::SPFCalculate (Ipv4Address root)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << root);
+  NS_LOG_FUNCTION (this << root);
 
   SPFVertex *v;
 //
@@ -1124,7 +1123,7 @@
   uint32_t
 GlobalRouteManagerImpl::FindOutgoingTypeId (Ipv4Address a, Ipv4Mask amask)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 //
 // We have an IP address <a> and a vertex ID of the root of the SPF tree.  
 // The question is what interface index does this address correspond to.
@@ -1200,7 +1199,7 @@
   void
 GlobalRouteManagerImpl::SPFIntraAddRouter (SPFVertex* v)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 
   NS_ASSERT_MSG (m_spfroot, 
     "GlobalRouteManagerImpl::SPFIntraAddRouter (): Root pointer not set");
@@ -1317,7 +1316,7 @@
   void
 GlobalRouteManagerImpl::SPFIntraAddTransit (SPFVertex* v)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 
   NS_ASSERT_MSG (m_spfroot, 
     "GlobalRouteManagerImpl::SPFIntraAddTransit (): Root pointer not set");
@@ -1410,7 +1409,7 @@
   void
 GlobalRouteManagerImpl::SPFVertexAddParent (SPFVertex* v)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   v->GetParent ()->AddChild (v);
 }
 
--- a/src/routing/global-routing/global-router-interface.cc	Mon Apr 14 16:39:26 2008 -0700
+++ b/src/routing/global-routing/global-router-interface.cc	Tue Apr 15 15:10:53 2008 -0700
@@ -43,7 +43,7 @@
   m_linkType (Unknown),
   m_metric (0)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 }
 
 GlobalRoutingLinkRecord::GlobalRoutingLinkRecord (
@@ -57,47 +57,46 @@
   m_linkType (linkType),
   m_metric (metric)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << linkType << linkId << linkData << metric);
+  NS_LOG_FUNCTION (this << linkType << linkId << linkData << metric);
 }
 
 GlobalRoutingLinkRecord::~GlobalRoutingLinkRecord ()
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 }
 
   Ipv4Address
 GlobalRoutingLinkRecord::GetLinkId (void) const
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   return m_linkId;
 }
 
   void
 GlobalRoutingLinkRecord::SetLinkId (Ipv4Address addr)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   m_linkId = addr;
 }
 
   Ipv4Address
 GlobalRoutingLinkRecord::GetLinkData (void) const
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   return m_linkData;
 }
 
   void
 GlobalRoutingLinkRecord::SetLinkData (Ipv4Address addr)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   m_linkData = addr;
 }
 
   GlobalRoutingLinkRecord::LinkType
 GlobalRoutingLinkRecord::GetLinkType (void) const
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   return m_linkType;
 }
 
@@ -105,21 +104,21 @@
 GlobalRoutingLinkRecord::SetLinkType (
   GlobalRoutingLinkRecord::LinkType linkType)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   m_linkType = linkType;
 }
 
   uint16_t
 GlobalRoutingLinkRecord::GetMetric (void) const
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   return m_metric;
 }
 
   void
 GlobalRoutingLinkRecord::SetMetric (uint16_t metric)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   m_metric = metric;
 }
 
@@ -139,7 +138,7 @@
   m_attachedRouters(),
   m_status(GlobalRoutingLSA::LSA_SPF_NOT_EXPLORED)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
 }
 
 GlobalRoutingLSA::GlobalRoutingLSA (
@@ -155,8 +154,7 @@
   m_attachedRouters(),
   m_status(status)
 {
-  NS_LOG_FUNCTION;
-  NS_LOG_PARAMS (this << status << linkStateId << advertisingRtr);
+  NS_LOG_FUNCTION (this << status << linkStateId << advertisingRtr);
 }
 
 GlobalRoutingLSA::GlobalRoutingLSA (GlobalRoutingLSA& lsa)
@@ -165,7 +163,7 @@
     m_networkLSANetworkMask(lsa.m_networkLSANetworkMask), 
     m_status(lsa.m_status)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   NS_ASSERT_MSG(IsEmpty(), 
     "GlobalRoutingLSA::GlobalRoutingLSA (): Non-empty LSA in constructor");
   CopyLinkRecords (lsa);
@@ -174,7 +172,7 @@
   GlobalRoutingLSA&
 GlobalRoutingLSA::operator= (const GlobalRoutingLSA& lsa)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   m_lsType = lsa.m_lsType;
   m_linkStateId = lsa.m_linkStateId;
   m_advertisingRtr = lsa.m_advertisingRtr;
@@ -189,7 +187,7 @@
   void
 GlobalRoutingLSA::CopyLinkRecords (const GlobalRoutingLSA& lsa)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   for (ListOfLinkRecords_t::const_iterator i = lsa.m_linkRecords.begin ();
        i != lsa.m_linkRecords.end (); 
        i++)
@@ -211,14 +209,14 @@
 
 GlobalRoutingLSA::~GlobalRoutingLSA()
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   ClearLinkRecords ();
 }
 
   void
 GlobalRoutingLSA::ClearLinkRecords(void)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   for ( ListOfLinkRecords_t::iterator i = m_linkRecords.begin ();
         i != m_linkRecords.end (); 
         i++)
@@ -238,7 +236,7 @@
   uint32_t
 GlobalRoutingLSA::AddLinkRecord (GlobalRoutingLinkRecord* lr)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   m_linkRecords.push_back (lr);
   return m_linkRecords.size ();
 }
@@ -246,14 +244,14 @@
   uint32_t
 GlobalRoutingLSA::GetNLinkRecords (void) const
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   return m_linkRecords.size ();
 }
 
   GlobalRoutingLinkRecord *
 GlobalRoutingLSA::GetLinkRecord (uint32_t n) const
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   uint32_t j = 0;
   for ( ListOfLinkRecords_t::const_iterator i = m_linkRecords.begin ();
         i != m_linkRecords.end (); 
@@ -271,77 +269,77 @@
   bool
 GlobalRoutingLSA::IsEmpty (void) const
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   return m_linkRecords.size () == 0;
 }
 
   GlobalRoutingLSA::LSType
 GlobalRoutingLSA::GetLSType (void) const
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   return m_lsType;
 }
 
   void 
 GlobalRoutingLSA::SetLSType (GlobalRoutingLSA::LSType typ) 
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   m_lsType = typ;
 }
 
   Ipv4Address
 GlobalRoutingLSA::GetLinkStateId (void) const
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   return m_linkStateId;
 }
 
   void
 GlobalRoutingLSA::SetLinkStateId (Ipv4Address addr)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   m_linkStateId = addr;
 }
 
   Ipv4Address
 GlobalRoutingLSA::GetAdvertisingRouter (void) const
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   return m_advertisingRtr;
 }
 
   void
 GlobalRoutingLSA::SetAdvertisingRouter (Ipv4Address addr)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   m_advertisingRtr = addr;
 }
 
   void 
 GlobalRoutingLSA::SetNetworkLSANetworkMask (Ipv4Mask mask)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   m_networkLSANetworkMask = mask;
 }
 
   Ipv4Mask 
 GlobalRoutingLSA::GetNetworkLSANetworkMask (void) const
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   return m_networkLSANetworkMask;
 }
 
   GlobalRoutingLSA::SPFStatus
 GlobalRoutingLSA::GetStatus (void) const
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   return m_status;
 }
 
   uint32_t 
 GlobalRoutingLSA::AddAttachedRouter (Ipv4Address addr)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   m_attachedRouters.push_back (addr);
   return m_attachedRouters.size ();
 }
@@ -349,14 +347,14 @@
   uint32_t 
 GlobalRoutingLSA::GetNAttachedRouters (void) const
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   return m_attachedRouters.size (); 
 }
 
   Ipv4Address 
 GlobalRoutingLSA::GetAttachedRouter (uint32_t n) const
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   uint32_t j = 0;
   for ( ListOfAttachedRouters_t::const_iterator i = m_attachedRouters.begin ();
         i != m_attachedRouters.end (); 
@@ -375,7 +373,7 @@
   void
 GlobalRoutingLSA::SetStatus (GlobalRoutingLSA::SPFStatus status)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   m_status = status;
 }
 
@@ -444,27 +442,27 @@
 GlobalRouter::GlobalRouter ()
   : m_LSAs()
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   m_routerId.Set(GlobalRouteManager::AllocateRouterId ());
 }
 
 GlobalRouter::~GlobalRouter ()
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   ClearLSAs();
 }
 
 void
 GlobalRouter::DoDispose ()
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   Object::DoDispose ();
 }
 
   void
 GlobalRouter::ClearLSAs ()
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   for ( ListOfLSAs_t::iterator i = m_LSAs.begin ();
         i != m_LSAs.end (); 
         i++)
@@ -484,7 +482,7 @@
   Ipv4Address
 GlobalRouter::GetRouterId (void) const
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   return m_routerId;
 }
 
@@ -495,7 +493,7 @@
   uint32_t 
 GlobalRouter::DiscoverLSAs (void)
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   Ptr<Node> node = GetObject<Node> ();
   NS_LOG_LOGIC("For node " << node->GetId () );
   NS_ASSERT_MSG(node, 
@@ -765,7 +763,7 @@
   uint32_t 
 GlobalRouter::GetNumLSAs (void) const
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   return m_LSAs.size ();
 }
 
@@ -775,7 +773,7 @@
   bool
 GlobalRouter::GetLSA (uint32_t n, GlobalRoutingLSA &lsa) const
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   NS_ASSERT_MSG(lsa.IsEmpty(), "GlobalRouter::GetLSA (): Must pass empty LSA");
 //
 // All of the work was done in GetNumLSAs.  All we have to do here is to
@@ -805,7 +803,7 @@
   Ptr<NetDevice>
 GlobalRouter::GetAdjacent(Ptr<NetDevice> nd, Ptr<Channel> ch) const
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   NS_ASSERT_MSG(ch->GetNDevices() == 2, 
     "GlobalRouter::GetAdjacent (): Channel with other than two devices");
 //
@@ -841,7 +839,7 @@
   uint32_t
 GlobalRouter::FindIfIndexForDevice(Ptr<Node> node, Ptr<NetDevice> nd) const
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   Ptr<Ipv4> ipv4 = node->GetObject<Ipv4> ();
   NS_ASSERT_MSG(ipv4, "QI for <Ipv4> interface failed");
   for (uint32_t i = 0; i < ipv4->GetNInterfaces(); ++i )
--- a/src/routing/olsr/routing-table.cc	Mon Apr 14 16:39:26 2008 -0700
+++ b/src/routing/olsr/routing-table.cc	Tue Apr 15 15:10:53 2008 -0700
@@ -40,7 +40,7 @@
 void
 RoutingTable::Clear ()
 {
-  NS_LOG_FUNCTION;
+  NS_LOG_FUNCTION_NOARGS ();
   m_table.clear ();
 }
 
@@ -183,7 +183,7 @@
                         uint32_t interface,
                         uint32_t distance)
 {
-  NS_LOG_PARAMS (this << dest << next << interface << distance << m_mainAddress);
+  NS_LOG_FUNCTION (this << dest << next << interface << distance << m_mainAddress);
 
   NS_ASSERT (distance > 0);
 
@@ -202,7 +202,7 @@
                         Ipv4Address const &interfaceAddress,
                         uint32_t distance)
 {
-  NS_LOG_PARAMS (this << dest << next << interfaceAddress << distance << m_mainAddress);
+  NS_LOG_FUNCTION (this << dest << next << interfaceAddress << distance << m_mainAddress);
 
   NS_ASSERT (distance > 0);
   NS_ASSERT (m_ipv4);