View | Details | Raw Unified | Return to bug 2070
Collapse All | Expand All

(-)i/src/internet/model/codel-queue.cc (+16 lines)
 Lines 399-404   CoDelQueue::DoDequeue (void) Link Here 
399
              // hence the while loop.
399
              // hence the while loop.
400
              NS_LOG_LOGIC ("Sojourn time is still above target and it's time for next drop; dropping " << p);
400
              NS_LOG_LOGIC ("Sojourn time is still above target and it's time for next drop; dropping " << p);
401
              Drop (p);
401
              Drop (p);
402
403
              // PLEASE !!! p was in queue, before entering this method.
404
              // You are silently dropping p, without updating the statistics
405
              // in Queue class. This fix such behaviour.
406
              m_traceDequeue (p);
407
              m_nBytes -= p->GetSize ();
408
              m_nPackets--;
409
402
              ++m_dropCount;
410
              ++m_dropCount;
403
              ++m_count;
411
              ++m_count;
404
              NewtonStep ();
412
              NewtonStep ();
 Lines 444-449   CoDelQueue::DoDequeue (void) Link Here 
444
          NS_LOG_LOGIC ("Sojourn time goes above target, dropping the first packet " << p << " and entering the dropping state");
452
          NS_LOG_LOGIC ("Sojourn time goes above target, dropping the first packet " << p << " and entering the dropping state");
445
          ++m_dropCount;
453
          ++m_dropCount;
446
          Drop (p);
454
          Drop (p);
455
456
          // PLEASE !!! p was in queue, before entering this method.
457
          // You are silently dropping p, without updating the statistics
458
          // in Queue class. This fix such behaviour.
459
          m_traceDequeue (p);
460
          m_nBytes -= p->GetSize ();
461
          m_nPackets--;
462
447
          if (m_packets.empty ())
463
          if (m_packets.empty ())
448
            {
464
            {
449
              m_dropping = false;
465
              m_dropping = false;
(-)i/src/network/utils/queue.h (-1 lines)
 Lines 180-186   protected: Link Here 
180
   */
180
   */
181
  void Drop (Ptr<Packet> packet);
181
  void Drop (Ptr<Packet> packet);
182
182
183
private:
184
  /// Traced callback: fired when a packet is enqueued
183
  /// Traced callback: fired when a packet is enqueued
185
  TracedCallback<Ptr<const Packet> > m_traceEnqueue;
184
  TracedCallback<Ptr<const Packet> > m_traceEnqueue;
186
  /// Traced callback: fired when a packet is dequeued
185
  /// Traced callback: fired when a packet is dequeued

Return to bug 2070