aboutsummaryrefslogtreecommitdiffstats
path: root/em-format
diff options
context:
space:
mode:
authorMilan Crha <mcrha@redhat.com>2012-11-06 23:20:46 +0800
committerMilan Crha <mcrha@redhat.com>2012-11-06 23:21:37 +0800
commit704b78d23bf8d707707411608a3453250f2637a1 (patch)
tree6bea89936534973c9b467503d198245f5035bc77 /em-format
parentb6fddaaa0efb8013c526f00926830b9cdcbe0d60 (diff)
downloadgsoc2013-evolution-704b78d23bf8d707707411608a3453250f2637a1.tar
gsoc2013-evolution-704b78d23bf8d707707411608a3453250f2637a1.tar.gz
gsoc2013-evolution-704b78d23bf8d707707411608a3453250f2637a1.tar.bz2
gsoc2013-evolution-704b78d23bf8d707707411608a3453250f2637a1.tar.lz
gsoc2013-evolution-704b78d23bf8d707707411608a3453250f2637a1.tar.xz
gsoc2013-evolution-704b78d23bf8d707707411608a3453250f2637a1.tar.zst
gsoc2013-evolution-704b78d23bf8d707707411608a3453250f2637a1.zip
Replace deprecated GLib symbols (as of GLib 2.34.x)
Diffstat (limited to 'em-format')
-rw-r--r--em-format/e-mail-parser.c13
1 files changed, 5 insertions, 8 deletions
diff --git a/em-format/e-mail-parser.c b/em-format/e-mail-parser.c
index c718f79425..69d74af623 100644
--- a/em-format/e-mail-parser.c
+++ b/em-format/e-mail-parser.c
@@ -37,7 +37,7 @@
static gpointer parent_class = 0;
struct _EMailParserPrivate {
- GMutex *mutex;
+ GMutex mutex;
gint last_error;
@@ -176,10 +176,7 @@ e_mail_parser_finalize (GObject *object)
priv = E_MAIL_PARSER (object)->priv;
- if (priv->mutex) {
- g_mutex_free (priv->mutex);
- priv->mutex = NULL;
- }
+ g_mutex_clear (&priv->mutex);
G_OBJECT_CLASS (parent_class)->finalize (object);
}
@@ -188,7 +185,7 @@ e_mail_parser_init (EMailParser *parser)
{
parser->priv = E_MAIL_PARSER_GET_PRIVATE (parser);
- parser->priv->mutex = g_mutex_new ();
+ g_mutex_init (&parser->priv->mutex);
}
static void
@@ -529,10 +526,10 @@ e_mail_parser_error (EMailParser *parser,
g_free (errmsg);
va_end (ap);
- g_mutex_lock (parser->priv->mutex);
+ g_mutex_lock (&parser->priv->mutex);
parser->priv->last_error++;
uri = g_strdup_printf (".error.%d", parser->priv->last_error);
- g_mutex_unlock (parser->priv->mutex);
+ g_mutex_unlock (&parser->priv->mutex);
mail_part = e_mail_part_new (part, uri);
mail_part->mime_type = g_strdup ("application/vnd.evolution.error");