output: consistently lock audio output objects
Always keep the audio_output object locked within the output thread, unless a plugin method is called. This fixes several race conditions.
This commit is contained in:
@@ -191,9 +191,9 @@ audio_output_init(struct audio_output *ao, const struct config_param *param,
|
||||
assert(ao->filter != NULL);
|
||||
|
||||
ao->thread = NULL;
|
||||
notify_init(&ao->notify);
|
||||
ao->command = AO_COMMAND_NONE;
|
||||
ao->mutex = g_mutex_new();
|
||||
ao->cond = g_cond_new();
|
||||
|
||||
ao->data = ao_plugin_init(plugin,
|
||||
&ao->config_audio_format,
|
||||
|
Reference in New Issue
Block a user