[vlc-commits] vdpau/deinterlace: allocate the p_sys with vlc_obj_malloc
Steve Lhomme
git at videolan.org
Tue Oct 13 11:07:15 CEST 2020
vlc | branch: master | Steve Lhomme <robux4 at ycbcr.xyz> | Tue Oct 13 09:24:19 2020 +0200| [3dcb9bf8d859bc90930f531800897bd8aa5dc2fc] | committer: Steve Lhomme
vdpau/deinterlace: allocate the p_sys with vlc_obj_malloc
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=3dcb9bf8d859bc90930f531800897bd8aa5dc2fc
---
modules/hw/vdpau/deinterlace.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/modules/hw/vdpau/deinterlace.c b/modules/hw/vdpau/deinterlace.c
index c2c4f85083..2edcbab71d 100644
--- a/modules/hw/vdpau/deinterlace.c
+++ b/modules/hw/vdpau/deinterlace.c
@@ -99,7 +99,6 @@ static picture_t *Deinterlace(filter_t *filter, picture_t *src)
static void Close(filter_t *filter)
{
vlc_video_context_Release(filter->vctx_out);
- free(filter->p_sys);
}
static const struct vlc_filter_operations filter_ops = {
@@ -118,7 +117,7 @@ static int Open(filter_t *filter)
if (!video_format_IsSimilar(&filter->fmt_in.video, &filter->fmt_out.video))
return VLC_EGENERIC;
- filter_sys_t *sys = malloc(sizeof (*sys));
+ filter_sys_t *sys = vlc_obj_malloc(VLC_OBJECT(filter), sizeof (*sys));
if (unlikely(sys == NULL))
return VLC_ENOMEM;
More information about the vlc-commits
mailing list