2007-04-05 Murray Cumming <murrayc@murrayc.com>
[modest] / src / modest-mail-operation.c
index cdde44a..f57bd80 100644 (file)
@@ -233,7 +233,7 @@ modest_mail_operation_send_new_mail (ModestMailOperation *self,
 {
        TnyMsg *new_msg;
        ModestMailOperationPrivate *priv = NULL;
-       GList *node = NULL;
+       /* GList *node = NULL; */
 
        g_return_if_fail (MODEST_IS_MAIL_OPERATION (self));
        g_return_if_fail (TNY_IS_TRANSPORT_ACCOUNT (transport_account));
@@ -765,6 +765,12 @@ on_refresh_folder_status_update (TnyFolder *folder, const gchar *msg,
        ModestMailOperation *self;
        ModestMailOperationPrivate *priv;
 
+       /* TODO: if tinymail issues a status update before the
+          callback call then this could happen. If this is true the
+          we must review the design */
+       if (!G_IS_OBJECT (user_data))
+         return;
+
        self = MODEST_MAIL_OPERATION (user_data);
        priv = MODEST_MAIL_OPERATION_GET_PRIVATE(self);