diff options
author | Guillaume Desmottes <guillaume.desmottes@collabora.co.uk> | 2011-10-25 21:23:30 +0800 |
---|---|---|
committer | Guillaume Desmottes <guillaume.desmottes@collabora.co.uk> | 2012-04-05 21:35:20 +0800 |
commit | 2c3892eb9f27b2c8dc8832402ceb06053f36b987 (patch) | |
tree | ec2bc40f1cf347642e28515622f3200d917221f7 /src/empathy-streamed-media-window.c | |
parent | ee2e583ba62e7bc1b6765a8115a78a4a74818d61 (diff) | |
download | gsoc2013-empathy-2c3892eb9f27b2c8dc8832402ceb06053f36b987.tar gsoc2013-empathy-2c3892eb9f27b2c8dc8832402ceb06053f36b987.tar.gz gsoc2013-empathy-2c3892eb9f27b2c8dc8832402ceb06053f36b987.tar.bz2 gsoc2013-empathy-2c3892eb9f27b2c8dc8832402ceb06053f36b987.tar.lz gsoc2013-empathy-2c3892eb9f27b2c8dc8832402ceb06053f36b987.tar.xz gsoc2013-empathy-2c3892eb9f27b2c8dc8832402ceb06053f36b987.tar.zst gsoc2013-empathy-2c3892eb9f27b2c8dc8832402ceb06053f36b987.zip |
Allocate GMutex on the stack
g_mutex_new() has been deprecated in GLib 2.31.
https://bugzilla.gnome.org/show_bug.cgi?id=662662
Diffstat (limited to 'src/empathy-streamed-media-window.c')
-rw-r--r-- | src/empathy-streamed-media-window.c | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/src/empathy-streamed-media-window.c b/src/empathy-streamed-media-window.c index deaae10d6..3bcb0e4f2 100644 --- a/src/empathy-streamed-media-window.c +++ b/src/empathy-streamed-media-window.c @@ -201,7 +201,7 @@ struct _EmpathyStreamedMediaWindowPriv GtkWidget *video_brightness; GtkWidget *video_gamma; - GMutex *lock; + GMutex lock; gboolean call_started; gboolean sending_video; CameraState camera_state; @@ -1035,7 +1035,7 @@ empathy_streamed_media_window_init (EmpathyStreamedMediaWindow *self) gtk_action_set_sensitive (priv->menu_fullscreen, FALSE); - priv->lock = g_mutex_new (); + g_mutex_init (&priv->lock); gtk_container_add (GTK_CONTAINER (self), top_vbox); @@ -1727,7 +1727,7 @@ empathy_streamed_media_window_finalize (GObject *object) disconnect_video_output_motion_handler (self); /* free any data held directly by the object here */ - g_mutex_free (priv->lock); + g_mutex_clear (&priv->lock); g_timer_destroy (priv->timer); @@ -1870,7 +1870,7 @@ empathy_streamed_media_window_disconnected (EmpathyStreamedMediaWindow *self, if (could_reset_pipeline) { - g_mutex_lock (priv->lock); + g_mutex_lock (&priv->lock); g_timer_stop (priv->timer); @@ -1878,7 +1878,7 @@ empathy_streamed_media_window_disconnected (EmpathyStreamedMediaWindow *self, g_source_remove (priv->timer_id); priv->timer_id = 0; - g_mutex_unlock (priv->lock); + g_mutex_unlock (&priv->lock); if (!restart) /* We are about to destroy the window, no need to update it or create @@ -2375,12 +2375,12 @@ empathy_streamed_media_window_connected (gpointer user_data) g_object_unref (call); - g_mutex_lock (priv->lock); + g_mutex_lock (&priv->lock); priv->timer_id = g_timeout_add_seconds (1, empathy_streamed_media_window_update_timer, self); - g_mutex_unlock (priv->lock); + g_mutex_unlock (&priv->lock); empathy_streamed_media_window_update_timer (self); @@ -2401,7 +2401,7 @@ empathy_streamed_media_window_src_added_cb (EmpathyStreamedMediaHandler *handler GstPad *pad; - g_mutex_lock (priv->lock); + g_mutex_lock (&priv->lock); if (priv->call_state != CONNECTED) { @@ -2467,7 +2467,7 @@ empathy_streamed_media_window_src_added_cb (EmpathyStreamedMediaHandler *handler } - g_mutex_unlock (priv->lock); + g_mutex_unlock (&priv->lock); return TRUE; } |