rem: if ( DEBUG ) printf ( "gsb_file_others_save_category : %s\n", filename );
add: devel_debug ( g_strdup_printf ("gsb_file_others_save_category : %s", filename ));
context: gboolean gsb_file_others_save_category ( gchar *filename ){    FILE *file;    gulong iterator;    gulong length_calculated;    gchar *file_content;    gulong length_part;    if ( DEBUG )	printf ( "gsb_file_others_save_category : %s\n",		 filename );    /* we begin to try to reserve enough memory to make the entire file     * if not enough, we will make it growth later     * the data below are about the memory to take for each part and for 1 of this part     * with that i think we will allocate enough memory in one time but not too much */    length_part = 500;        length_calculated = length_part * g_slist_length (gsb_data_category_get_categories_list());    iterator = 0;    file_content = g_malloc ( length_calculated );    /* begin the file whit xml markup */        iterator = gsb_file_save_append_part ( iterator,					   &length_calculated,					   &file_content,					   g_strdup ("<?xml version=\"1.0\"?>\n<Grisbi_categ>\n"));    iterator = gsb_file_others_save_general_part ( iterator,						   &length_calculated,						   &file_content,						   VERSION_FICHIER_CATEG );    iterator = gsb_file_save_category_part ( iterator,					     &length_calculated,					     &file_content );    /* finish the file */    iterator = gsb_file_save_append_part ( iterator,					   &length_calculated,					   &file_content,					   g_strdup ("</Grisbi_categ>"));    /* the file is in memory, we can save it */    file = fopen ( filename,			  "w" );    if ( !file	 ||	 !fwrite ( file_content,		   sizeof (gchar),		   iterator,		   file ))    {	dialogue_error ( g_strdup_printf ( _("Cannot save file '%s': %s"),					   filename,					   latin2utf8(strerror(errno)) ));	free ( file_content);	return ( FALSE );    }        fclose (file);    free ( file_content);    return ( TRUE );}