From 2e6566611d5bd15f792bc7872959a4b625382cab Mon Sep 17 00:00:00 2001 From: Ettore Perazzoli Date: Sat, 2 Feb 2002 15:55:19 +0000 Subject: Allocate the ConnectionList list with the right number of entries instead * e-summary-offline-handler.c (create_connection_list): Allocate the ConnectionList list with the right number of entries instead of zero. svn path=/trunk/; revision=15552 --- my-evolution/ChangeLog | 6 ++++++ my-evolution/e-summary-offline-handler.c | 5 +++-- 2 files changed, 9 insertions(+), 2 deletions(-) diff --git a/my-evolution/ChangeLog b/my-evolution/ChangeLog index 283a974ce0..ce2893b8bf 100644 --- a/my-evolution/ChangeLog +++ b/my-evolution/ChangeLog @@ -1,3 +1,9 @@ +2002-02-02 Ettore Perazzoli + + * e-summary-offline-handler.c (create_connection_list): Allocate + the ConnectionList list with the right number of entries instead + of zero. + 2002-02-01 Ettore Perazzoli [Fix a crash that can happen if you have opened multiple views of diff --git a/my-evolution/e-summary-offline-handler.c b/my-evolution/e-summary-offline-handler.c index da54180981..a9163b578e 100644 --- a/my-evolution/e-summary-offline-handler.c +++ b/my-evolution/e-summary-offline-handler.c @@ -69,11 +69,12 @@ create_connection_list (GSList *summaries) list = GNOME_Evolution_ConnectionList__alloc (); list->_length = 0; list->_maximum = 0; - list->_buffer = CORBA_sequence_GNOME_Evolution_Connection_allocbuf (list->_maximum); /* Count the total number of connections first to make CORBA happy. */ for (sp = summaries; sp != NULL; sp = sp->next) - list->_maximum += e_summary_count_connections (E_SUMMARY (sp->data)) + 1; + list->_maximum += e_summary_count_connections (E_SUMMARY (sp->data)); + + list->_buffer = CORBA_sequence_GNOME_Evolution_Connection_allocbuf (list->_maximum); for (sp = summaries; sp != NULL; sp = sp->next) { ESummary *summary; -- cgit v1.2.3