summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorThomas Vander Stichele <thomas@apestaart.org>2004-01-19 18:22:57 +0000
committerThomas Vander Stichele <thomas@apestaart.org>2004-01-19 18:22:57 +0000
commita9fe376339a81588a8eec973f6a96b33d1e2d27a (patch)
treece263db5882493c2264b8970cc28d70aa47e020f
parent5a2ceb9ba0b534f67c8c2b44b54a4d24bb258ae5 (diff)
downloadgst-plugins-bad-a9fe376339a81588a8eec973f6a96b33d1e2d27a.tar.gz
gst-plugins-bad-a9fe376339a81588a8eec973f6a96b33d1e2d27a.tar.bz2
gst-plugins-bad-a9fe376339a81588a8eec973f6a96b33d1e2d27a.zip
fix element_error
Original commit message from CVS: fix element_error
-rw-r--r--ChangeLog7
-rw-r--r--sys/v4l2/v4l2-overlay_calls.c23
2 files changed, 18 insertions, 12 deletions
diff --git a/ChangeLog b/ChangeLog
index 7a24d685..175d134e 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,12 @@
2004-01-19 Thomas Vander Stichele <thomas at apestaart dot org>
+ * sys/v4l/v4l-overlay_calls.c: (gst_v4l_set_overlay):
+ * sys/v4l2/v4l2-overlay_calls.c: (gst_v4l2_set_display),
+ (gst_v4l2_set_window), (gst_v4l2_enable_overlay):
+ fix element_error
+
+2004-01-19 Thomas Vander Stichele <thomas at apestaart dot org>
+
* sys/v4l/v4l_calls.h:
* sys/v4l2/v4l2_calls.h:
element_error fixes
diff --git a/sys/v4l2/v4l2-overlay_calls.c b/sys/v4l2/v4l2-overlay_calls.c
index 2de74269..b455ba3c 100644
--- a/sys/v4l2/v4l2-overlay_calls.c
+++ b/sys/v4l2/v4l2-overlay_calls.c
@@ -59,17 +59,17 @@ gst_v4l2_set_display (GstV4l2Element *v4l2element)
switch (system(buff)) {
case -1:
- gst_element_error(GST_ELEMENT(v4l2element),
- "Could not start v4l-conf: %s",
- g_strerror(errno));
+ gst_element_error (v4l2element, RESOURCE, FAILED,
+ (_("Could not start v4l-conf")),
+ GST_ERROR_SYSTEM);
g_free(buff);
return FALSE;
case 0:
break;
default:
- gst_element_error(GST_ELEMENT(v4l2element),
- "v4l-conf failed to run correctly: %s",
- g_strerror(errno));
+ gst_element_error (v4l2element, RESOURCE, FAILED,
+ (_("Executing v4l-conf failed")),
+ GST_ERROR_SYSTEM);
g_free(buff);
return FALSE;
}
@@ -112,9 +112,8 @@ gst_v4l2_set_window (GstElement *element,
fmt.fmt.win.bitmap = NULL;
if (ioctl(v4l2element->video_fd, VIDIOC_S_FMT, &fmt) < 0) {
- gst_element_error(GST_ELEMENT(v4l2element),
- "Failed to set the video window on device %s: %s",
- v4l2element->device, g_strerror(errno));
+ gst_element_error (v4l2element, RESOURCE, TOO_LAZY, NULL,
+ ("Failed to set the video window: %s", g_strerror (errno)));
return FALSE;
}
@@ -139,9 +138,9 @@ gst_v4l2_enable_overlay (GstV4l2Element *v4l2element,
GST_V4L2_CHECK_OVERLAY(v4l2element);
if (ioctl(v4l2element->video_fd, VIDIOC_OVERLAY, &doit) < 0) {
- gst_element_error(GST_ELEMENT(v4l2element),
- "Failed to %s overlay display for device %s: %s",
- enable?"enable":"disable", v4l2element->device, g_strerror(errno));
+ gst_element_error (v4l2element, RESOURCE, TOO_LAZY, NULL,
+ ("Failed to %s overlay display: %s",
+ enable?"enable":"disable", g_strerror (errno)));
return FALSE;
}