aboutsummaryrefslogtreecommitdiffstats
path: root/mail/mail-ops.c
diff options
context:
space:
mode:
authorEttore Perazzoli <ettore@src.gnome.org>2000-08-14 04:35:44 +0800
committerEttore Perazzoli <ettore@src.gnome.org>2000-08-14 04:35:44 +0800
commite1111e8e763aae61113117debde9931dcf642b76 (patch)
tree99db0f1a5b3df0830f936300d0be87445cf7e2a8 /mail/mail-ops.c
parent639b2e2157425d4b4c011c1e74a91bb02a2e9338 (diff)
downloadgsoc2013-evolution-e1111e8e763aae61113117debde9931dcf642b76.tar
gsoc2013-evolution-e1111e8e763aae61113117debde9931dcf642b76.tar.gz
gsoc2013-evolution-e1111e8e763aae61113117debde9931dcf642b76.tar.bz2
gsoc2013-evolution-e1111e8e763aae61113117debde9931dcf642b76.tar.lz
gsoc2013-evolution-e1111e8e763aae61113117debde9931dcf642b76.tar.xz
gsoc2013-evolution-e1111e8e763aae61113117debde9931dcf642b76.tar.zst
gsoc2013-evolution-e1111e8e763aae61113117debde9931dcf642b76.zip
Fix bug in the folder creation code: CORBA_Object_duplicate() the
CORBA listener before storing it. svn path=/trunk/; revision=4804
Diffstat (limited to 'mail/mail-ops.c')
-rw-r--r--mail/mail-ops.c15
1 files changed, 9 insertions, 6 deletions
diff --git a/mail/mail-ops.c b/mail/mail-ops.c
index 9ba7f29e1c..787b23bd43 100644
--- a/mail/mail-ops.c
+++ b/mail/mail-ops.c
@@ -1330,8 +1330,6 @@ setup_create_folder (gpointer in_data, gpointer op_data, CamelException *ex)
"No type passed to create_folder");
return;
}
-
- /* FIXME: reference listener somehow? */
}
static void
@@ -1378,12 +1376,12 @@ cleanup_create_folder (gpointer in_data, gpointer op_data,
camel_exception_set (ex, CAMEL_EXCEPTION_SYSTEM,
"Exception while reporting result to shell "
"component listener.");
- CORBA_exception_free (&ev);
-
- /* FIXME: unref listener somehow? */
+ CORBA_free (input->listener);
g_free (input->uri);
g_free (input->type);
+
+ CORBA_exception_free (&ev);
}
static const mail_operation_spec op_create_folder = {
@@ -1398,13 +1396,18 @@ void
mail_do_create_folder (const Evolution_ShellComponentListener listener,
const char *uri, const char *type)
{
+ CORBA_Environment ev;
create_folder_input_t *input;
+ CORBA_exception_init (&ev);
+
input = g_new (create_folder_input_t, 1);
- input->listener = listener;
+ input->listener = CORBA_Object_duplicate (listener, &ev);
input->uri = g_strdup (uri);
input->type = g_strdup (type);
+ CORBA_exception_free (&ev);
+
mail_operation_queue (&op_create_folder, input, FALSE);
}