mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-04-16 21:14:44 +00:00
sys/v4l/v4lsrc_calls.c: Don't actually error out if we get another return value than
Original commit message from CVS: * sys/v4l/v4lsrc_calls.c: (gst_v4lsrc_try_capture): Don't actually error out if we get another return value than -EINVAL. Opposite to what I first thought, drivers have random return values for this, although -EINVAL is the expected return value. Since this is not fatal, we shouldn't use GST_ELEMENT_ERROR() but just GST_ERROR_OBJECT().
This commit is contained in:
parent
eb13b061c6
commit
c626afd60a
2 changed files with 11 additions and 2 deletions
|
@ -1,3 +1,12 @@
|
|||
2004-10-01 Ronald S. Bultje <rbultje@ronald.bitfreak.net>
|
||||
|
||||
* sys/v4l/v4lsrc_calls.c: (gst_v4lsrc_try_capture):
|
||||
Don't actually error out if we get another return value than
|
||||
-EINVAL. Opposite to what I first thought, drivers have random
|
||||
return values for this, although -EINVAL is the expected return
|
||||
value. Since this is not fatal, we shouldn't use
|
||||
GST_ELEMENT_ERROR() but just GST_ERROR_OBJECT().
|
||||
|
||||
2004-10-01 Ronald S. Bultje <rbultje@ronald.bitfreak.net>
|
||||
|
||||
* ext/dvdread/dvdreadsrc.c: (dvdreadsrc_class_init),
|
||||
|
|
|
@ -494,8 +494,8 @@ gst_v4lsrc_try_capture (GstV4lSrc * v4lsrc, gint width, gint height,
|
|||
vmmap.frame = frame;
|
||||
if (ioctl (GST_V4LELEMENT (v4lsrc)->video_fd, VIDIOCMCAPTURE, &vmmap) < 0) {
|
||||
if (errno != EINVAL) /* our format failed! */
|
||||
GST_ELEMENT_ERROR (v4lsrc, RESOURCE, OPEN_READ_WRITE, (NULL),
|
||||
("Error queueing our try-out buffer: %s", g_strerror (errno)));
|
||||
GST_ERROR_OBJECT (v4lsrc,
|
||||
"Error queueing our try-out buffer: %s", g_strerror (errno));
|
||||
munmap (buffer, vmbuf.size);
|
||||
return FALSE;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue