summaryrefslogtreecommitdiffstats
path: root/src/uca-camera.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/uca-camera.c')
-rw-r--r--src/uca-camera.c14
1 files changed, 10 insertions, 4 deletions
diff --git a/src/uca-camera.c b/src/uca-camera.c
index f517d87..a7b266a 100644
--- a/src/uca-camera.c
+++ b/src/uca-camera.c
@@ -211,12 +211,15 @@ void uca_camera_start_recording(UcaCamera *camera, GError **error)
return;
}
- (*klass->start_recording)(camera, error);
+ GError *tmp_error = NULL;
+ (*klass->start_recording)(camera, &tmp_error);
- if (error == NULL) {
+ if (tmp_error == NULL) {
camera->priv->recording = TRUE;
g_object_notify_by_pspec(G_OBJECT(camera), camera_properties[PROP_IS_RECORDING]);
}
+ else
+ g_propagate_error(error, tmp_error);
}
void uca_camera_stop_recording(UcaCamera *camera, GError **error)
@@ -234,12 +237,15 @@ void uca_camera_stop_recording(UcaCamera *camera, GError **error)
return;
}
- (*klass->stop_recording)(camera, error);
+ GError *tmp_error = NULL;
+ (*klass->stop_recording)(camera, &tmp_error);
- if (error == NULL) {
+ if (tmp_error == NULL) {
camera->priv->recording = FALSE;
g_object_notify_by_pspec(G_OBJECT(camera), camera_properties[PROP_IS_RECORDING]);
}
+ else
+ g_propagate_error(error, tmp_error);
}
void uca_camera_set_grab_func(UcaCamera *camera, UcaCameraGrabFunc func)