Fixes leak 2/26
authorSergio Villar Senin <svillar@igalia.com>
Tue, 17 Mar 2009 19:29:42 +0000 (19:29 +0000)
committerSergio Villar Senin <svillar@igalia.com>
Tue, 17 Mar 2009 19:29:42 +0000 (19:29 +0000)
pmo-trunk-r8107

src/modest-ui-actions.c

index ecb7d75..ab4c62e 100644 (file)
@@ -1358,7 +1358,7 @@ open_msg_performer(gboolean canceled,
                    gpointer user_data)
 {
        ModestMailOperation *mail_op = NULL;
                    gpointer user_data)
 {
        ModestMailOperation *mail_op = NULL;
-       gchar *error_msg;
+       gchar *error_msg = NULL;
        ModestProtocolType proto;
        TnyConnectionStatus status;
        OpenMsgHelper *helper = NULL;
        ModestProtocolType proto;
        TnyConnectionStatus status;
        OpenMsgHelper *helper = NULL;
@@ -1483,6 +1483,8 @@ open_msg_performer(gboolean canceled,
 
        /* Frees */
  clean:
 
        /* Frees */
  clean:
+       if (error_msg)
+               g_free (error_msg);
        if (mail_op)
                g_object_unref (mail_op);
        g_object_unref (account);
        if (mail_op)
                g_object_unref (mail_op);
        g_object_unref (account);