[java-atk-wrapper] jawimpl.c: use g_mutex_init
- From: Magdalen Berns <mberns src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [java-atk-wrapper] jawimpl.c: use g_mutex_init
- Date: Thu, 20 Nov 2014 20:43:39 +0000 (UTC)
commit 6654ea425e82229c1fb0b88e0d6bcf1a4f591346
Author: Magdalen Berns <m berns thismagpie com>
Date: Thu Nov 20 20:42:30 2014 +0000
jawimpl.c: use g_mutex_init
do not use deprecated g_mutex_new, instead used g_mutex_init
Bug: https://bugzilla.gnome.org/show_bug.cgi?id=740459
jni/src/jawimpl.c | 12 ++++++++----
1 files changed, 8 insertions(+), 4 deletions(-)
---
diff --git a/jni/src/jawimpl.c b/jni/src/jawimpl.c
index a0c4567..9b7ad69 100644
--- a/jni/src/jawimpl.c
+++ b/jni/src/jawimpl.c
@@ -84,13 +84,17 @@ static GHashTable *typeTable = NULL;
static GHashTable *objectTable = NULL;
static GMutex *objectTableMutex = NULL;
+typedef struct {
+ GMutex jg_mutex;
+} JGMutex;
+
+JGMutex *jmutex;
+
void
jaw_impl_init_mutex ()
{
- if (objectTableMutex == NULL)
- {
- objectTableMutex = g_mutex_new();
- }
+ jmutex = g_new(JGMutex, 1);
+ g_mutex_init (&jmutex->jg_mutex);
}
static void
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]