1
0
Fork 0
mirror of https://github.com/deltachat/deltachat-core.git synced 2025-10-06 03:50:08 +02:00

do not delay the deletion of securejoin-messages

This commit is contained in:
B. Petersen 2018-06-18 21:07:48 +02:00
parent 2875f22e5a
commit 62f09a9fff

View file

@ -806,14 +806,14 @@ int mrmailbox_handle_securejoin_handshake(mrmailbox_t* mailbox, mrmimeparser_t*
end_bobs_joining(mailbox, BOB_SUCCESS); end_bobs_joining(mailbox, BOB_SUCCESS);
} }
// delete the message in 20 seconds - typical handshake last about 5 seconds, so do not disturb the connection _now_. // delete the message, as SMTP and IMAP is done in separate threads it should be okay to delete the message just now.
// for errors, we do not the corresoinding message at all, it may come eg. from another device or may be useful to find out what was going wrong. // for errors, we do not the corresponding message at all, it may come eg. from another device or may be useful to find out what was going wrong.
if( ret == MR_IS_HANDSHAKE_STOP_NORMAL_PROCESSING ) { if( ret == MR_IS_HANDSHAKE_STOP_NORMAL_PROCESSING ) {
struct mailimf_field* field; struct mailimf_field* field;
if( (field=mrmimeparser_lookup_field(mimeparser, "Message-ID"))!=NULL && field->fld_type==MAILIMF_FIELD_MESSAGE_ID ) { if( (field=mrmimeparser_lookup_field(mimeparser, "Message-ID"))!=NULL && field->fld_type==MAILIMF_FIELD_MESSAGE_ID ) {
struct mailimf_message_id* fld_message_id = field->fld_data.fld_message_id; struct mailimf_message_id* fld_message_id = field->fld_data.fld_message_id;
if( fld_message_id && fld_message_id->mid_value ) { if( fld_message_id && fld_message_id->mid_value ) {
mrjob_add(mailbox, MRJ_DELETE_MSG_ON_IMAP, mrmailbox_rfc724_mid_exists__(mailbox, fld_message_id->mid_value, NULL, NULL), NULL, 20); mrjob_add(mailbox, MRJ_DELETE_MSG_ON_IMAP, mrmailbox_rfc724_mid_exists__(mailbox, fld_message_id->mid_value, NULL, NULL), NULL, 0);
} }
} }
} }