-rw-r--r-- | kmicromail/libetpan/mh/mailmh.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/kmicromail/libetpan/mh/mailmh.c b/kmicromail/libetpan/mh/mailmh.c index 5e2b4cc..1087ce1 100644 --- a/kmicromail/libetpan/mh/mailmh.c +++ b/kmicromail/libetpan/mh/mailmh.c | |||
@@ -390,24 +390,29 @@ int mailmh_folder_update(struct mailmh_folder * folder) | |||
390 | key.data = &msg_info->msg_index; | 390 | key.data = &msg_info->msg_index; |
391 | key.len = sizeof(msg_info->msg_index); | 391 | key.len = sizeof(msg_info->msg_index); |
392 | data.data = msg_info; | 392 | data.data = msg_info; |
393 | data.len = 0; | 393 | data.len = 0; |
394 | 394 | ||
395 | r = chash_set(folder->fl_msgs_hash, &key, &data, NULL); | 395 | r = chash_set(folder->fl_msgs_hash, &key, &data, NULL); |
396 | if (r < 0) { | 396 | if (r < 0) { |
397 | carray_delete_fast(folder->fl_msgs_tab, msg_info->msg_array_index); | 397 | carray_delete_fast(folder->fl_msgs_tab, msg_info->msg_array_index); |
398 | mailmh_msg_info_free(msg_info); | 398 | mailmh_msg_info_free(msg_info); |
399 | res = MAILMH_ERROR_MEMORY; | 399 | res = MAILMH_ERROR_MEMORY; |
400 | goto closedir; | 400 | goto closedir; |
401 | } | 401 | } |
402 | //LR memory leak? added next line | ||
403 | //mailmh_msg_info_free(msg_info); | ||
404 | //it seems so that it should be freed later, | ||
405 | // but it is not in every case | ||
406 | //PENDING fixme in ompi somewhere | ||
402 | } | 407 | } |
403 | } | 408 | } |
404 | else if (S_ISDIR(buf.st_mode)) { | 409 | else if (S_ISDIR(buf.st_mode)) { |
405 | struct mailmh_folder * subfolder; | 410 | struct mailmh_folder * subfolder; |
406 | unsigned int array_index; | 411 | unsigned int array_index; |
407 | chashdatum key; | 412 | chashdatum key; |
408 | chashdatum data; | 413 | chashdatum data; |
409 | 414 | ||
410 | if (ent->d_name[0] == '.') { | 415 | if (ent->d_name[0] == '.') { |
411 | if (ent->d_name[1] == 0) | 416 | if (ent->d_name[1] == 0) |
412 | continue; | 417 | continue; |
413 | if ((ent->d_name[1] == '.') && (ent->d_name[2] == 0)) | 418 | if ((ent->d_name[1] == '.') && (ent->d_name[2] == 0)) |