mirror of
https://github.com/xenia-project/FFmpeg.git
synced 2025-03-07 11:38:53 +00:00
avformat/hls: Fix memleak when url is empty
Fixes Coverity ID 1465888. Reviewed-by: Steven Liu <lingjiujianke@gmail.com> Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
This commit is contained in:
parent
ab384d289d
commit
dfc6a9f075
@ -311,8 +311,10 @@ static struct playlist *new_playlist(HLSContext *c, const char *url,
|
||||
return NULL;
|
||||
reset_packet(&pls->pkt);
|
||||
ff_make_absolute_url(pls->url, sizeof(pls->url), base, url);
|
||||
if (!pls->url[0])
|
||||
if (!pls->url[0]) {
|
||||
av_free(pls);
|
||||
return NULL;
|
||||
}
|
||||
pls->seek_timestamp = AV_NOPTS_VALUE;
|
||||
|
||||
pls->is_id3_timestamped = -1;
|
||||
|
Loading…
x
Reference in New Issue
Block a user