Commit 8e1a72a2 authored by Rémi Denis-Courmont's avatar Rémi Denis-Courmont

spu: avoid pointless alloc and indirection

parent 398cabc6
...@@ -165,7 +165,6 @@ static void FilterRelease(filter_t *filter) ...@@ -165,7 +165,6 @@ static void FilterRelease(filter_t *filter)
{ {
if (filter->p_module) if (filter->p_module)
module_unneed(filter, filter->p_module); module_unneed(filter, filter->p_module);
free(filter->owner.sys);
vlc_object_release(filter); vlc_object_release(filter);
} }
...@@ -186,8 +185,7 @@ static int spu_get_attachments(filter_t *filter, ...@@ -186,8 +185,7 @@ static int spu_get_attachments(filter_t *filter,
input_attachment_t ***attachment_ptr, input_attachment_t ***attachment_ptr,
int *attachment_count) int *attachment_count)
{ {
filter_owner_sys_t *sys = filter->owner.sys; spu_t *spu = filter->owner.sys;
spu_t *spu = sys->spu;
int ret = VLC_EGENERIC; int ret = VLC_EGENERIC;
if (spu->p->input) if (spu->p->input)
...@@ -203,9 +201,7 @@ static filter_t *SpuRenderCreateAndLoadText(spu_t *spu) ...@@ -203,9 +201,7 @@ static filter_t *SpuRenderCreateAndLoadText(spu_t *spu)
if (!text) if (!text)
return NULL; return NULL;
filter_owner_sys_t *sys = xmalloc(sizeof(*sys)); text->owner.sys = spu;
sys->spu = spu;
text->owner.sys = sys;
es_format_Init(&text->fmt_in, VIDEO_ES, 0); es_format_Init(&text->fmt_in, VIDEO_ES, 0);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment