From 0b44016ef66788795dab051f4c9408cbc79d4978 Mon Sep 17 00:00:00 2001 From: Pablo Neira Ayuso Date: Thu, 28 Aug 2014 14:28:23 +0200 Subject: osmux: fix leak in osmux_replay_lost_packets() The original RTP header has been already sanity check. Therefore, we can assume the clone is sane. --- src/osmux.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'src') diff --git a/src/osmux.c b/src/osmux.c index 61e3fc4..9288464 100644 --- a/src/osmux.c +++ b/src/osmux.c @@ -400,9 +400,8 @@ static void osmux_replay_lost_packets(struct batch_list_node *node, memcpy(clone->data, last->data, last->len); msgb_put(clone, last->len); + /* The original RTP message has been already sanity check. */ rtph = osmo_rtp_get_hdr(clone); - if (rtph == NULL) - return; /* Adjust sequence number and timestamp */ rtph->sequence = htons(ntohs(rtph->sequence) + i); -- cgit v1.2.3