From bd2a27113a72193fba48667145bb4168ab93da4f Mon Sep 17 00:00:00 2001 From: Tommaso Pecorella Date: Sun, 30 Apr 2017 00:05:35 +0200 Subject: [PATCH] applications: (fixes #2732) BulkSend Tx trace is fired too much --- src/applications/model/bulk-send-application.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/applications/model/bulk-send-application.cc b/src/applications/model/bulk-send-application.cc index 65ef8932b..74980e4f8 100644 --- a/src/applications/model/bulk-send-application.cc +++ b/src/applications/model/bulk-send-application.cc @@ -194,11 +194,11 @@ void BulkSendApplication::SendData (void) NS_LOG_LOGIC ("sending packet at " << Simulator::Now ()); Ptr packet = Create (toSend); - m_txTrace (packet); int actual = m_socket->Send (packet); if (actual > 0) { m_totBytes += actual; + m_txTrace (packet); } // We exit this loop when actual < toSend as the send side // buffer is full. The "DataSent" callback will pop when