output/openal: fix default device name

This commit is contained in:
Serge Ziryukin 2009-09-06 22:33:34 +03:00 committed by Max Kellermann
parent 4ebf53ffdf
commit eefef369ea
1 changed files with 3 additions and 3 deletions

View File

@ -123,13 +123,13 @@ openal_init(G_GNUC_UNUSED const struct audio_format *audio_format,
const char *device_name = config_get_block_string(param, "device", NULL);
struct openal_data *od;
od = g_new(struct openal_data, 1);
od->device_name = device_name;
if (device_name == NULL) {
device_name = alcGetString(NULL, ALC_DEFAULT_DEVICE_SPECIFIER);
}
od = g_new(struct openal_data, 1);
od->device_name = device_name;
return od;
}