From 6229cd14f15ac6b3ba82ea5110ced18cc96bde1e Mon Sep 17 00:00:00 2001 From: JP Rosevear Date: Fri, 27 Jul 2001 01:00:33 +0000 Subject: free a list of attendees (meeting_page_fill_widgets): clean up attendee 2001-07-26 JP Rosevear * gui/dialogs/meeting-page.c (cleanup_attendees): free a list of attendees (meeting_page_fill_widgets): clean up attendee lists and fix typo (find_match): add ability to return pos of match (popup_delete_cb): if deletion happens, make sure to tidy up delegation chain * gui/dialogs/e-delegate-dialog.c (e_delegate_dialog_construct): use the destination rather than text property (e_delegate_dialog_get_delegate): ditto (e_delegate_dialog_new): take name/address pair for dialog default * gui/dialogs/e-delegate-dialog.h: update protos * gui/e-itip-control.c (clean_up): only unref the object if we have one * gui/itip-control-factory.c (stream_read): make sure we null terminate the final buffer * gui/itip-utils.c (itip_send_comp): strip the mailto: from the organizer address if necessary svn path=/trunk/; revision=11440 --- calendar/gui/itip-bonobo-control.c | 15 ++++++--------- 1 file changed, 6 insertions(+), 9 deletions(-) (limited to 'calendar/gui/itip-bonobo-control.c') diff --git a/calendar/gui/itip-bonobo-control.c b/calendar/gui/itip-bonobo-control.c index 9c8068bde0..1fca85f10d 100644 --- a/calendar/gui/itip-bonobo-control.c +++ b/calendar/gui/itip-bonobo-control.c @@ -54,7 +54,7 @@ static char * stream_read (Bonobo_Stream stream) { Bonobo_Stream_iobuf *buffer; - CORBA_Environment ev; + CORBA_Environment ev; gchar *data = NULL; gint length = 0; @@ -72,18 +72,15 @@ stream_read (Bonobo_Stream stream) if (buffer->_length <= 0) break; - data = g_realloc (data, - length + buffer->_length); - - memcpy (data + length, - buffer->_buffer, buffer->_length); - + data = g_realloc (data, length + buffer->_length + 1); + memcpy (data + length, buffer->_buffer, buffer->_length); length += buffer->_length; - + data[length] = '\0'; + CORBA_free (buffer); #undef READ_CHUNK_SIZE } while (1); - + CORBA_free (buffer); CORBA_exception_free (&ev); -- cgit v1.2.3