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

amem: fix conditionally unitialized cleanup callback

parent 9b904a74
......@@ -56,12 +56,12 @@ struct aout_sys_t
{
void *opaque;
int (*setup) (void **, char *, unsigned *, unsigned *);
void (*cleanup) (void *opaque);
union
{
struct
{
void *setup_opaque;
void (*cleanup) (void *opaque);
};
struct
{
......@@ -243,11 +243,12 @@ static int Open (vlc_object_t *obj)
sys->setup = var_InheritAddress (obj, "amem-setup");
if (sys->setup != NULL)
{
sys->setup_opaque = opaque;
sys->cleanup = var_InheritAddress (obj, "amem-cleanup");
sys->setup_opaque = opaque;
}
else
{
sys->cleanup = NULL;
sys->opaque = opaque;
sys->rate = var_InheritInteger (obj, "amem-rate");
sys->channels = var_InheritInteger (obj, "amem-channels");
......
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