Hello, I am changing link layer, implemented in ~ns/mac/ll.{h, cc}, to give support for header compression. It occurs a strange thing as I change the code to drop packets that doesn't have any context saved in the node. Instead of dropping just the packet passed by parameter into the link layer, all other packets that weren't specified are dropped in the queue(IFQ).
-------------- --------- Link Layer => IFQ <-- here it happens the losses! -------------- --------- It follows a part of sendDown() method of LL class( in ll.cc): ************************************************************************************* #ifdef HEADER_COMPRESSION_VOIP if (ch->ptype() == PT_CBR) { if( (ih->id() % 10) == 0 ) { // if it is a uncompressed packet if ( ! (bkp_fields->existe_item(ih->flowid())) ) // if there is no saved context with given "flowid" // save the identification of context bkp_fields->inserir(ih->flowid()); } else { if( bkp_fields->existe_item(ih->flowid()) ) printf("Compressed packet\n"); // goes to the queue else { printf("Loss packet\n); drop(p); // it is dropped here, doesn't go to the queue <-- Here is the problem!!! } } } #endif Scheduler& s = Scheduler::instance(); // let mac decide when to take a new packet from the queue. s.schedule(downtarget_, p, delay_); } // end of the method ******************************************************************************************* Can anybody help me to solve this problem? Any suggestion is welcome. Thank you very much in advance, Laércio Jr. Manaus-Amazonas-Brazil