fix mem leak in RLC UM test and RLC AM stress tester

master
Andre Puschmann 7 years ago
parent 1be93d4682
commit a6ccb05bb1

@ -85,6 +85,7 @@ private:
usleep(100); usleep(100);
} }
running = false; running = false;
byte_buffer_pool::get_instance()->deallocate(pdu);
} }
rlc_interface_mac *rlc1; rlc_interface_mac *rlc1;

@ -62,6 +62,14 @@ public:
n_sdus = 0; n_sdus = 0;
} }
~rlc_um_tester(){
for (uint32_t i = 0; i < NBUFS; i++) {
if (sdus[i] != NULL) {
byte_buffer_pool::get_instance()->deallocate(sdus[i]);
}
}
}
// PDCP interface // PDCP interface
void write_pdu(uint32_t lcid, byte_buffer_t *sdu) void write_pdu(uint32_t lcid, byte_buffer_t *sdu)
{ {

Loading…
Cancel
Save