ext/alsa/: 'Could not open resource for writing' is not an acceptable even less so when we're trying to open it to re...

Original commit message from CVS:
* ext/alsa/gstalsasink.c: (gst_alsasink_open):
* ext/alsa/gstalsasrc.c: (gst_alsasrc_open):
'Could not open resource for writing' is not an acceptable
error message when we can't open the audio device (see #492334),
even less so when we're trying to open it to record something.
This commit is contained in:
Tim-Philipp Müller 2007-11-03 10:39:21 +00:00
parent 63f7f64a7b
commit 5c279f449a
3 changed files with 21 additions and 7 deletions

View file

@ -1,3 +1,11 @@
2007-11-03 Tim-Philipp Müller <tim at centricular dot net>
* ext/alsa/gstalsasink.c: (gst_alsasink_open):
* ext/alsa/gstalsasrc.c: (gst_alsasrc_open):
'Could not open resource for writing' is not an acceptable
error message when we can't open the audio device (see #492334),
even less so when we're trying to open it to record something.
2007-11-02 Tim-Philipp Müller <tim at centricular dot net>
Patch by: Ole André Vadla Ravnås <ole.andre.ravnas@tandberg.com>

View file

@ -645,11 +645,14 @@ gst_alsasink_open (GstAudioSink * asink)
open_error:
{
if (err == -EBUSY) {
GST_ELEMENT_ERROR (alsa, RESOURCE, BUSY, (NULL), ("Device '%s' is busy",
alsa->device));
GST_ELEMENT_ERROR (alsa, RESOURCE, BUSY,
(_("Could not open audio device for playback. "
"Device is being used by another application.")),
("Device '%s' is busy", alsa->device));
} else {
GST_ELEMENT_ERROR (alsa, RESOURCE, OPEN_WRITE,
(NULL), ("Playback open error on device '%s': %s", alsa->device,
(_("Could not open audio device for playback.")),
("Playback open error on device '%s': %s", alsa->device,
snd_strerror (err)));
}
return FALSE;

View file

@ -622,11 +622,14 @@ gst_alsasrc_open (GstAudioSrc * asrc)
open_error:
{
if (err == -EBUSY) {
GST_ELEMENT_ERROR (alsa, RESOURCE, BUSY, (NULL), ("Device '%s' is busy",
alsa->device));
GST_ELEMENT_ERROR (alsa, RESOURCE, BUSY,
(_("Could not open audio device for recording. "
"Device is being used by another application.")),
("Device '%s' is busy", alsa->device));
} else {
GST_ELEMENT_ERROR (alsa, RESOURCE, OPEN_WRITE,
(NULL), ("Recording open error on device '%s': %s", alsa->device,
GST_ELEMENT_ERROR (alsa, RESOURCE, OPEN_READ,
(_("Could not open audio device for recording.")),
("Recording open error on device '%s': %s", alsa->device,
snd_strerror (err)));
}
return FALSE;