diff options
author | Matthias Vogelgesang <matthias.vogelgesang@gmail.com> | 2012-04-20 11:10:53 +0200 |
---|---|---|
committer | Matthias Vogelgesang <matthias.vogelgesang@gmail.com> | 2012-04-20 11:10:53 +0200 |
commit | f159f5f6ebc891ca4ecdfa600f1bc427fece5f07 (patch) | |
tree | 7c63888a64960aa121b6db75af668361cb4379bd /test | |
parent | 025dfc0c41367d5b29381e6ab26d3d58fe75d931 (diff) | |
download | uca-f159f5f6ebc891ca4ecdfa600f1bc427fece5f07.tar.gz uca-f159f5f6ebc891ca4ecdfa600f1bc427fece5f07.tar.bz2 uca-f159f5f6ebc891ca4ecdfa600f1bc427fece5f07.tar.xz uca-f159f5f6ebc891ca4ecdfa600f1bc427fece5f07.zip |
Output error when stopping
Diffstat (limited to 'test')
-rw-r--r-- | test/control.c | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/test/control.c b/test/control.c index 4990e5e..5afbb7d 100644 --- a/test/control.c +++ b/test/control.c @@ -174,7 +174,11 @@ static void on_toolbutton_stop_clicked(GtkWidget *widget, gpointer args) ThreadData *data = (ThreadData *) args; data->running = FALSE; data->store = FALSE; - uca_camera_stop_recording(data->camera, NULL); + GError *error = NULL; + uca_camera_stop_recording(data->camera, &error); + + if (error != NULL) + g_printerr("Failed to stop: %s\n", error->message); } static void on_toolbutton_record_clicked(GtkWidget *widget, gpointer args) @@ -190,9 +194,8 @@ static void on_toolbutton_record_clicked(GtkWidget *widget, gpointer args) data->running = TRUE; uca_camera_start_recording(data->camera, &error); - if (!g_thread_create(grab_thread, data, FALSE, &error)) { + if (!g_thread_create(grab_thread, data, FALSE, &error)) g_printerr("Failed to create thread: %s\n", error->message); - } } } @@ -220,7 +223,7 @@ static void on_valuecell_edited(GtkCellRendererText *renderer, gchar *path, gcha gtk_list_store_set(GTK_LIST_STORE(td->property_model), &iter, COLUMN_VALUE, g_value_get_string(&src_value), -1); } else - g_print("Couldn't transform %s\n", g_value_get_string(&src_value)); + g_warning("Couldn't transform %s\n", g_value_get_string(&src_value)); } } |