return;
for (i=0;i<user_set->len;i++) {
- GPtrArray *infos = g_array_index (user_set, struct _imapx_flag_change, i).infos;
+ struct _imapx_flag_change *flag_change = &g_array_index (user_set, struct _imapx_flag_change, i);
+ GPtrArray *infos = flag_change->infos;
gint j;
for (j = 0; j < infos->len; j++) {
}
g_ptr_array_free(infos, TRUE);
+ g_free (flag_change->name);
}
g_array_free(user_set, TRUE);
}
uids = camel_folder_summary_get_changed (folder->summary);
if (uids->len == 0) {
- g_ptr_array_free (uids, TRUE);
+ camel_folder_free_uids (folder, uids);
return TRUE;
}
} else {
GArray *user_set;
CamelFlag *user_flag;
- struct _imapx_flag_change *change = NULL, add;
+ struct _imapx_flag_change *change = NULL, add = { 0 };
if (res < 0) {
if (on_user == NULL)
camel_message_info_free (info);
}
- if ((on_orset|off_orset) == 0 && on_user == NULL && off_user == NULL)
- return TRUE;
+ if ((on_orset|off_orset) == 0 && on_user == NULL && off_user == NULL) {
+ success = TRUE;
+ goto done;
+ }
/* TODO above code should go into changes_start */