$ git clone http://tcclient.ion.nu/tc_client.git
commit 8bdf158f1877ca098f193d131bad2ff4aad66463
Author: Alicia <...>
Date: Sat Oct 15 11:43:02 2016 +0200
tc_client-gtk: bugfix: close the camera device when cancelling cam selection.
diff --git a/ChangeLog b/ChangeLog
index 49add71..d12ad88 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -27,6 +27,7 @@ tc_client-gtk: added support for broadcasting audio.
tc_client-gtk: fixed some warnings found with G_DEBUG="fatal-criticals".
tc_client-gtk: quit if the captcha window is closed.
tc_client-gtk: make scrolling with page up and page down work even if focus is on the input field.
+tc_client-gtk: bugfix: close the camera device when cancelling cam selection.
tc_client-gtk and camviewer: updated to libavcodec's avcodec_{send,receive}_{frame,packet} API.
camviewer: removed the old, buggy audio code.
libcamera: added support for a virtual X11 camera.
diff --git a/utilities/gtk/media.c b/utilities/gtk/media.c
index 18615aa..fc1cc36 100644
--- a/utilities/gtk/media.c
+++ b/utilities/gtk/media.c
@@ -370,6 +370,11 @@ gboolean camselect_cancel(GtkWidget* widget, void* x1, void* x2)
gtk_widget_hide(window);
g_source_remove(camselect.eventsource);
camselect.eventsource=0;
+ if(camselect.current)
+ {
+ cam_close(camselect.current);
+ camselect.current=0;
+ }
if(camselect.cancelcallback){camselect.cancelcallback();}
return 1;
}