diff options
author | Ettore Perazzoli <ettore@src.gnome.org> | 2001-08-08 18:47:48 +0800 |
---|---|---|
committer | Ettore Perazzoli <ettore@src.gnome.org> | 2001-08-08 18:47:48 +0800 |
commit | 8a3a5c7b9abdd77b08382b3382bc2c832204c234 (patch) | |
tree | 651b7119bbc3dc635c013d874f192b98e7f81d74 /shell | |
parent | 581740ce36eed13bed3e269fde3c0f117f3950ac (diff) | |
download | gsoc2013-evolution-8a3a5c7b9abdd77b08382b3382bc2c832204c234.tar.gz gsoc2013-evolution-8a3a5c7b9abdd77b08382b3382bc2c832204c234.tar.zst gsoc2013-evolution-8a3a5c7b9abdd77b08382b3382bc2c832204c234.zip |
Set the release flag on the sequence, and CORBA_string_dup() the strings
* evolution-shell-component.c
(fill_corba_sequence_from_null_terminated_string_array): Set the
release flag on the sequence, and CORBA_string_dup() the strings
anyway.
svn path=/trunk/; revision=11781
Diffstat (limited to 'shell')
-rw-r--r-- | shell/ChangeLog | 7 | ||||
-rw-r--r-- | shell/evolution-shell-component.c | 6 |
2 files changed, 9 insertions, 4 deletions
diff --git a/shell/ChangeLog b/shell/ChangeLog index 2d4a31a267..74368d26c4 100644 --- a/shell/ChangeLog +++ b/shell/ChangeLog @@ -1,6 +1,13 @@ 2001-08-08 Ettore Perazzoli <ettore@ximian.com> * evolution-shell-component.c + (fill_corba_sequence_from_null_terminated_string_array): Set the + release flag on the sequence, and CORBA_string_dup() the strings + anyway. + +2001-08-08 Ettore Perazzoli <ettore@ximian.com> + + * evolution-shell-component.c (impl_ShellComponent__get_supported_types): Set the release flag on the returned folder type list too. diff --git a/shell/evolution-shell-component.c b/shell/evolution-shell-component.c index c01b43bb8e..bb1e7481f9 100644 --- a/shell/evolution-shell-component.c +++ b/shell/evolution-shell-component.c @@ -109,9 +109,7 @@ fill_corba_sequence_from_null_terminated_string_array (CORBA_sequence_CORBA_stri g_assert (corba_sequence != NULL); g_assert (array != NULL); - /* We won't be reallocating the strings, so we don't want them to be - freed when the sequence is freed. */ - CORBA_sequence_set_release (corba_sequence, FALSE); + CORBA_sequence_set_release (corba_sequence, TRUE); count = 0; while (array[count] != NULL) @@ -122,7 +120,7 @@ fill_corba_sequence_from_null_terminated_string_array (CORBA_sequence_CORBA_stri corba_sequence->_buffer = CORBA_sequence_CORBA_string_allocbuf (count); for (i = 0; i < count; i++) - corba_sequence->_buffer[i] = (CORBA_char *) array[i]; + corba_sequence->_buffer[i] = CORBA_string_dup (array[i]); } |