mirror of
https://github.com/chatmail/core.git
synced 2026-05-08 09:26:29 +03:00
run cargo fmt
This commit is contained in:
@@ -199,8 +199,7 @@ pub unsafe fn dc_receive_imf(
|
||||
ok_to_continue = false;
|
||||
} else {
|
||||
msgrmsg = mime_parser.is_send_by_messenger;
|
||||
if msgrmsg == 0
|
||||
&& 0 != dc_is_reply_to_messenger_message(context, &mime_parser)
|
||||
if msgrmsg == 0 && 0 != dc_is_reply_to_messenger_message(context, &mime_parser)
|
||||
{
|
||||
msgrmsg = 2
|
||||
}
|
||||
@@ -301,9 +300,7 @@ pub unsafe fn dc_receive_imf(
|
||||
if 0 == create_blocked_0 {
|
||||
dc_unblock_chat(context, chat_id);
|
||||
chat_id_blocked = 0
|
||||
} else if 0
|
||||
!= dc_is_reply_to_known_message(context, &mime_parser)
|
||||
{
|
||||
} else if 0 != dc_is_reply_to_known_message(context, &mime_parser) {
|
||||
dc_scaleup_contact_origin(context, from_id, 0x100);
|
||||
info!(
|
||||
context,
|
||||
@@ -361,8 +358,7 @@ pub unsafe fn dc_receive_imf(
|
||||
&mut chat_id,
|
||||
&mut chat_id_blocked,
|
||||
);
|
||||
if 0 != chat_id && 0 != chat_id_blocked && 0 == create_blocked_1
|
||||
{
|
||||
if 0 != chat_id && 0 != chat_id_blocked && 0 == create_blocked_1 {
|
||||
dc_unblock_chat(context, chat_id);
|
||||
chat_id_blocked = 0
|
||||
}
|
||||
@@ -543,10 +539,7 @@ pub unsafe fn dc_receive_imf(
|
||||
if ok_to_continue {
|
||||
info!(
|
||||
context,
|
||||
0,
|
||||
"Message has {} parts and is assigned to chat #{}.",
|
||||
icnt,
|
||||
chat_id,
|
||||
0, "Message has {} parts and is assigned to chat #{}.", icnt, chat_id,
|
||||
);
|
||||
if chat_id == 3 as libc::c_uint {
|
||||
create_event_to_send = None;
|
||||
@@ -559,11 +552,7 @@ pub unsafe fn dc_receive_imf(
|
||||
create_event_to_send = Some(Event::INCOMING_MSG);
|
||||
}
|
||||
}
|
||||
dc_do_heuristics_moves(
|
||||
context,
|
||||
server_folder.as_ref(),
|
||||
insert_msg_id,
|
||||
);
|
||||
dc_do_heuristics_moves(context, server_folder.as_ref(), insert_msg_id);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -601,8 +590,7 @@ pub unsafe fn dc_receive_imf(
|
||||
.first
|
||||
.is_null()
|
||||
{
|
||||
(*(*(*report_root).mm_data.mm_multipart.mm_mp_list)
|
||||
.first)
|
||||
(*(*(*report_root).mm_data.mm_multipart.mm_mp_list).first)
|
||||
.next
|
||||
} else {
|
||||
0 as *mut clistcell
|
||||
@@ -648,8 +636,7 @@ pub unsafe fn dc_receive_imf(
|
||||
&mut report_body_bytes,
|
||||
&mut to_mmap_string_unref,
|
||||
) {
|
||||
let mut report_parsed: *mut mailmime =
|
||||
0 as *mut mailmime;
|
||||
let mut report_parsed: *mut mailmime = 0 as *mut mailmime;
|
||||
let mut dummy: size_t = 0 as size_t;
|
||||
if mailmime_parse(
|
||||
report_body,
|
||||
@@ -662,14 +649,12 @@ pub unsafe fn dc_receive_imf(
|
||||
let report_fields: *mut mailimf_fields =
|
||||
mailmime_find_mailimf_fields(report_parsed);
|
||||
if !report_fields.is_null() {
|
||||
let of_disposition:
|
||||
*mut mailimf_optional_field =
|
||||
mailimf_find_optional_field(report_fields,
|
||||
b"Disposition\x00"
|
||||
as
|
||||
*const u8
|
||||
as
|
||||
*const libc::c_char);
|
||||
let of_disposition: *mut mailimf_optional_field =
|
||||
mailimf_find_optional_field(
|
||||
report_fields,
|
||||
b"Disposition\x00" as *const u8
|
||||
as *const libc::c_char,
|
||||
);
|
||||
let of_org_msgid: *mut mailimf_optional_field =
|
||||
mailimf_find_optional_field(
|
||||
report_fields,
|
||||
@@ -692,10 +677,8 @@ pub unsafe fn dc_receive_imf(
|
||||
) == MAIL_NO_ERROR as libc::c_int
|
||||
&& !rfc724_mid_0.is_null()
|
||||
{
|
||||
let mut chat_id_0: uint32_t =
|
||||
0 as uint32_t;
|
||||
let mut msg_id: uint32_t =
|
||||
0 as uint32_t;
|
||||
let mut chat_id_0: uint32_t = 0 as uint32_t;
|
||||
let mut msg_id: uint32_t = 0 as uint32_t;
|
||||
if 0 != dc_mdn_from_ext(
|
||||
context,
|
||||
from_id,
|
||||
@@ -704,12 +687,10 @@ pub unsafe fn dc_receive_imf(
|
||||
&mut chat_id_0,
|
||||
&mut msg_id,
|
||||
) {
|
||||
rr_event_to_send
|
||||
.push((chat_id_0, 0));
|
||||
rr_event_to_send.push((chat_id_0, 0));
|
||||
rr_event_to_send.push((msg_id, 0));
|
||||
}
|
||||
mdn_consumed = (msg_id
|
||||
!= 0 as libc::c_uint)
|
||||
mdn_consumed = (msg_id != 0 as libc::c_uint)
|
||||
as libc::c_int;
|
||||
free(rfc724_mid_0 as *mut libc::c_void);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user