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
@ -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>
|
2004-10-01 Ronald S. Bultje <rbultje@ronald.bitfreak.net>
|
||||||
|
|
||||||
* ext/dvdread/dvdreadsrc.c: (dvdreadsrc_class_init),
|
* ext/dvdread/dvdreadsrc.c: (dvdreadsrc_class_init),
|
||||||
|
@ -494,8 +494,8 @@ gst_v4lsrc_try_capture (GstV4lSrc * v4lsrc, gint width, gint height,
|
|||||||
vmmap.frame = frame;
|
vmmap.frame = frame;
|
||||||
if (ioctl (GST_V4LELEMENT (v4lsrc)->video_fd, VIDIOCMCAPTURE, &vmmap) < 0) {
|
if (ioctl (GST_V4LELEMENT (v4lsrc)->video_fd, VIDIOCMCAPTURE, &vmmap) < 0) {
|
||||||
if (errno != EINVAL) /* our format failed! */
|
if (errno != EINVAL) /* our format failed! */
|
||||||
GST_ELEMENT_ERROR (v4lsrc, RESOURCE, OPEN_READ_WRITE, (NULL),
|
GST_ERROR_OBJECT (v4lsrc,
|
||||||
("Error queueing our try-out buffer: %s", g_strerror (errno)));
|
"Error queueing our try-out buffer: %s", g_strerror (errno));
|
||||||
munmap (buffer, vmbuf.size);
|
munmap (buffer, vmbuf.size);
|
||||||
return FALSE;
|
return FALSE;
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user