1
0
mirror of https://github.com/profanity-im/profanity.git synced 2024-06-23 21:45:30 +00:00

Fix issue with first encrypted message

When decrypting first message with prekey, libsignal wants to remove
used prekey from storage. Return value on success should be 0.

We used to return number of deleted keys. Thus libsignal was considering
we failed to remove the key and we were ignoring plaintext.
This commit is contained in:
Paul Fariello 2019-04-10 18:58:06 +03:20
parent df648ba959
commit ad21021ce7

View File

@ -225,7 +225,11 @@ remove_pre_key(uint32_t pre_key_id, void *user_data)
omemo_identity_keyfile_save();
return ret;
if (ret > 0) {
return SG_SUCCESS;
} else {
return SG_ERR_INVALID_KEY_ID;
}
}
int