mgcp_sdp: fix potential leak

Change-Id: I31527b54f602634024a0b687eef26a9b29354282
This commit is contained in:
Eric Wild 2021-08-06 01:40:14 +02:00
parent 958f5e74cc
commit e303fa9ff3
1 changed files with 3 additions and 1 deletions

View File

@ -394,8 +394,10 @@ int mgcp_parse_sdp_data(const struct mgcp_endpoint *endp,
codecs_used = rc;
break;
case 'c':
if (audio_ip_from_sdp(&rtp->addr, line) < 0)
if (audio_ip_from_sdp(&rtp->addr, line) < 0) {
talloc_free(tmp_ctx);
return -1;
}
break;
default:
if (endp)