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

Fix crash if PulseAudio is compiled-in but not used

parent ed864e7f
...@@ -368,6 +368,7 @@ static int Open(vlc_object_t *obj) ...@@ -368,6 +368,7 @@ static int Open(vlc_object_t *obj)
aout_sys_t *sys = malloc(sizeof(*sys)); aout_sys_t *sys = malloc(sizeof(*sys));
if (unlikely(sys == NULL)) if (unlikely(sys == NULL))
return VLC_ENOMEM; return VLC_ENOMEM;
aout->output.p_sys = sys;
sys->context = NULL; sys->context = NULL;
sys->stream = NULL; sys->stream = NULL;
//sys->byterate = byterate; //sys->byterate = byterate;
...@@ -428,7 +429,6 @@ static int Open(vlc_object_t *obj) ...@@ -428,7 +429,6 @@ static int Open(vlc_object_t *obj)
aout->output.i_nb_samples = pba->minreq / pa_frame_size(&ss); aout->output.i_nb_samples = pba->minreq / pa_frame_size(&ss);
pa_threaded_mainloop_unlock(mainloop); pa_threaded_mainloop_unlock(mainloop);
aout->output.p_sys = sys;
aout->output.pf_play = Play; aout->output.pf_play = Play;
aout_VolumeSoftInit(aout); aout_VolumeSoftInit(aout);
return VLC_SUCCESS; return VLC_SUCCESS;
......
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