Created
January 13, 2012 16:15
-
-
Save shadeslayer/1607267 to your computer and use it in GitHub Desktop.
Since GLib 2.31 GStaticRecMutex has been deprecated and GRecMutex is used instead. We do not need to initialize GRecMutex since it is static
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/agent/agent.c b/agent/agent.c | |
index 298a8ec..2adeb30 100644 | |
--- a/agent/agent.c | |
+++ b/agent/agent.c | |
@@ -120,7 +120,7 @@ enum | |
static guint signals[N_SIGNALS]; | |
-static GStaticRecMutex agent_mutex = G_STATIC_REC_MUTEX_INIT; /* Mutex used for thread-safe lib */ | |
+static GRecMutex agent_mutex; /* Mutex used for thread-safe lib */ | |
static gboolean priv_attach_stream_component (NiceAgent *agent, | |
Stream *stream, | |
@@ -132,12 +132,12 @@ static void priv_free_upnp (NiceAgent *agent); | |
void agent_lock (void) | |
{ | |
- g_static_rec_mutex_lock (&agent_mutex); | |
+ g_rec_mutex_lock (&agent_mutex); | |
} | |
void agent_unlock (void) | |
{ | |
- g_static_rec_mutex_unlock (&agent_mutex); | |
+ g_rec_mutex_unlock (&agent_mutex); | |
} | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment