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

ALSA: log the device string that is actually opened

(cherry picked from commit 45db0215add18231b00e3ebdf7762a0e68da5b2a)
parent 6d7114a6
......@@ -382,20 +382,21 @@ static int Start (audio_output_t *aout, audio_sample_format_t *restrict fmt)
const int mode = SND_PCM_NO_AUTO_RESAMPLE;
int val = snd_pcm_open (&pcm, device, SND_PCM_STREAM_PLAYBACK, mode);
free (devbuf);
if (val != 0)
{
msg_Err (aout, "cannot open ALSA device \"%s\": %s", sys->device,
msg_Err (aout, "cannot open ALSA device \"%s\": %s", device,
snd_strerror (val));
dialog_Fatal (aout, _("Audio output failed"),
_("The audio device \"%s\" could not be used:\n%s."),
sys->device, snd_strerror (val));
free (devbuf);
return VLC_EGENERIC;
}
sys->pcm = pcm;
/* Print some potentially useful debug */
msg_Dbg (aout, "using ALSA device: %s", sys->device);
msg_Dbg (aout, "using ALSA device: %s", device);
free (devbuf);
DumpDevice (VLC_OBJECT(aout), pcm);
/* Get Initial hardware parameters */
......
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