Re: [evolution-patches] Fixes for #57218 and #54280



On Mon, 2004-05-24 at 20:31 +0530, Harish Krishnaswamy wrote:
> ooops..i forgot to remove the dead code..
> this is the modified patch

> Index: calendar/backends/groupwise/e-cal-backend-groupwise.c
> ===================================================================
> RCS file:
> /cvs/gnome/evolution-data-server/calendar/backends/groupwise/e-cal-backend-groupwise.c,v
> retrieving revision 1.68
> diff -u -p -r1.68 e-cal-backend-groupwise.c
> --- calendar/backends/groupwise/e-cal-backend-groupwise.c	18 May 2004
> 17:16:54 -0000	1.68
> +++ calendar/backends/groupwise/e-cal-backend-groupwise.c	24 May 2004
> 15:00:12 -0000
> @@ -1001,6 +1001,7 @@ e_cal_backend_groupwise_modify_object (E
>  	EGwConnectionStatus status;
>  	EGwItem *item, *cache_item;
>  
> +	*old_object = NULL;
>  	cbgw = E_CAL_BACKEND_GROUPWISE (backend);
>  	priv = cbgw->priv;
>  
> @@ -1049,6 +1050,7 @@ e_cal_backend_groupwise_modify_object (E
>  
>  	g_object_unref (comp);
>  
> +	*old_object = g_strdup (calobj);
>
'calobj' is the new object, as sent from the client. You should use
cache_comp here.

> @@ -1257,7 +1267,19 @@ e_cal_backend_groupwise_send_objects (EC
>  		status = send_object (cbgw, cal, icalcomp);
>  	} else
>  		status = GNOME_Evolution_Calendar_InvalidObject;
> -
> +	
> +	if (status == GNOME_Evolution_Calendar_Success) {
> +		ECalComponent *comp;
> +
> +		comp = e_cal_component_new ();
> +		e_cal_component_set_icalcomponent (comp, icalcomp);
> +		
> +		if (comp) {
> +			e_cal_component_get_attendee_list (comp, users);
> +			g_object_unref (comp);	
> +		}
>
you should check for 'comp' not being NULL after e_cal_component_new,
which is not needed at all. So, instead, you should:

	if (e_cal_component_set_icalcomponent (comp, icalcomp)) {
		e_cal_component_get_attendee_list ...

cheers




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]