+2012-10-12 [colin] 3.8.1cvs93
+
+ * src/compose.c
+ * src/prefs_account.c
+ * src/common/utils.c
+ * src/common/utils.h
+ Fix bug #2751 'g_mutex_new/g_mutex_free removed from GLib 2.32'
+ Thanks to Salvatore de Paolis
+
2012-10-10 [colin] 3.8.1cvs92
* src/folder.c
( cvs diff -u -r 1.149.2.111 -r 1.149.2.112 src/inc.c; cvs diff -u -r 1.28.2.53 -r 1.28.2.54 src/mbox.c; cvs diff -u -r 1.11.2.32 -r 1.11.2.33 src/common/smtp.c; cvs diff -u -r 1.6.2.21 -r 1.6.2.22 src/common/smtp.h; ) > 3.8.1cvs90.patchset
( cvs diff -u -r 1.60.2.65 -r 1.60.2.66 src/procmsg.h; ) > 3.8.1cvs91.patchset
( cvs diff -u -r 1.213.2.215 -r 1.213.2.216 src/folder.c; cvs diff -u -r 1.1.2.116 -r 1.1.2.117 src/gtk/quicksearch.c; ) > 3.8.1cvs92.patchset
+( cvs diff -u -r 1.382.2.615 -r 1.382.2.616 src/compose.c; cvs diff -u -r 1.105.2.177 -r 1.105.2.178 src/prefs_account.c; cvs diff -u -r 1.36.2.203 -r 1.36.2.204 src/common/utils.c; cvs diff -u -r 1.20.2.80 -r 1.20.2.81 src/common/utils.h; ) > 3.8.1cvs93.patchset
MICRO_VERSION=1
INTERFACE_AGE=0
BINARY_AGE=0
-EXTRA_VERSION=92
+EXTRA_VERSION=93
EXTRA_RELEASE=
EXTRA_GTK2_VERSION=
}
return g_unlink(filename);
}
+
+GMutex *cm_mutex_new(void) {
+#if GLIB_CHECK_VERSION(2,32,0)
+ GMutex *m = mutex;
+ m = g_new0(GMutex, 1);
+ g_mutex_init(m);
+ return m;
+#else
+ return g_mutex_new();
+#endif
+}
+
+void cm_mutex_free(GMutex *mutex) {
+#if GLIB_CHECK_VERSION(2,32,0)
+ g_mutex_clear(mutex);
+ g_free(m);
+#else
+ g_mutex_free(mutex);
+#endif
+}
gboolean sc_g_slist_bigger(GSList *list, gint max);
int claws_unlink(const gchar *filename);
+
+GMutex *cm_mutex_new(void);
+void cm_mutex_free(GMutex *mutex);
+
#ifdef __cplusplus
}
#endif
compose->account = account;
compose->folder = folder;
- compose->mutex = g_mutex_new();
+ compose->mutex = cm_mutex_new();
compose->set_cursor_pos = -1;
#if !(GTK_CHECK_VERSION(2,12,0))
gtk_widget_destroy(compose->window);
toolbar_destroy(compose->toolbar);
g_free(compose->toolbar);
- g_mutex_free(compose->mutex);
+ cm_mutex_free(compose->mutex);
g_free(compose);
}
struct GetPassData pass_data;
/* do complicated stuff to be able to call GTK from the mainloop */
pass_data.cond = g_cond_new();
- pass_data.mutex = g_mutex_new();
+ pass_data.mutex = cm_mutex_new();
pass_data.pass = (gchar **)source;
g_mutex_lock(pass_data.mutex);
g_cond_wait(pass_data.cond, pass_data.mutex);
g_cond_free(pass_data.cond);
g_mutex_unlock(pass_data.mutex);
- g_mutex_free(pass_data.mutex);
+ cm_mutex_free(pass_data.mutex);
return TRUE;
}