diff options
author | Holger Hans Peter Freyther <holger@moiji-mobile.com> | 2015-03-28 17:30:31 +0100 |
---|---|---|
committer | Holger Hans Peter Freyther <holger@moiji-mobile.com> | 2015-03-28 17:56:16 +0100 |
commit | 37b5ce56a0650eeb8a3c6b788d1c9ba16139b313 (patch) | |
tree | 526eb09af45045eac691367a5c1bd0ecc9bf3260 /openbsc/src/libtrau | |
parent | 9967a57587b9dcc1eeeaa710159447eb098380f3 (diff) |
rtp: Fix memory leak fixed by Andreas without mentioning it
We allocate the msgb at entry of the method and we always need
to msgb_free it.
Diffstat (limited to 'openbsc/src/libtrau')
-rw-r--r-- | openbsc/src/libtrau/rtp_proxy.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/openbsc/src/libtrau/rtp_proxy.c b/openbsc/src/libtrau/rtp_proxy.c index 82f4063b2..be00dde3b 100644 --- a/openbsc/src/libtrau/rtp_proxy.c +++ b/openbsc/src/libtrau/rtp_proxy.c @@ -394,7 +394,7 @@ static int rtp_socket_read(struct rtp_socket *rs, struct rtp_sub_socket *rss) rc = read(rss->bfd.fd, msg->data, RTP_ALLOC_SIZE); if (rc <= 0) { rss->bfd.when &= ~BSC_FD_READ; - return rc; + goto out_free; } msgb_put(msg, rc); |