[cheese/camerabin2] cheese-camera: Fix leak inserted at the last commit
- From: Thiago Sousa Santos <thiagoss src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [cheese/camerabin2] cheese-camera: Fix leak inserted at the last commit
- Date: Mon, 30 Apr 2012 12:48:18 +0000 (UTC)
commit c7ea1546245d96821db6c0dbd3d0a3a2509d5e53
Author: Thiago Santos <thiago sousa santos collabora com>
Date: Mon Apr 30 09:47:45 2012 -0300
cheese-camera: Fix leak inserted at the last commit
Do not forget to unref the element after getting it from camerabin
libcheese/cheese-camera.c | 4 +++-
1 files changed, 3 insertions(+), 1 deletions(-)
---
diff --git a/libcheese/cheese-camera.c b/libcheese/cheese-camera.c
index cfc62f0..d4be6f5 100644
--- a/libcheese/cheese-camera.c
+++ b/libcheese/cheese-camera.c
@@ -1774,8 +1774,10 @@ cheese_camera_get_recorded_time (CheeseCamera *camera)
gboolean ret = FALSE;
videosink = gst_bin_get_by_name (priv->camerabin, "videobin-filesink");
- if (videosink)
+ if (videosink) {
ret = gst_element_query_position (videosink, &format, &curtime);
+ gst_object_unref (videosink);
+ }
if (ret) {
// Substract seconds, minutes and hours.
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]