avformat/mpegtsenc: Use av_freep() to avoid leaving stale pointers in memory
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
This commit is contained in:
parent
47b9481d9d
commit
f7a4589b36
@ -814,9 +814,9 @@ fail:
|
||||
service = ts->services[i];
|
||||
av_freep(&service->provider_name);
|
||||
av_freep(&service->name);
|
||||
av_free(service);
|
||||
av_freep(&service);
|
||||
}
|
||||
av_free(ts->services);
|
||||
av_freep(&ts->services);
|
||||
return ret;
|
||||
}
|
||||
|
||||
@ -1417,9 +1417,9 @@ static int mpegts_write_end(AVFormatContext *s)
|
||||
service = ts->services[i];
|
||||
av_freep(&service->provider_name);
|
||||
av_freep(&service->name);
|
||||
av_free(service);
|
||||
av_freep(&service);
|
||||
}
|
||||
av_free(ts->services);
|
||||
av_freep(&ts->services);
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user