[lib] reset session and resend message when device is unable to decrypt messages
Summary:
ENG-6982.
We want to reset session when there was an error while decrypting.
Depends on D13033
Test Plan:
- Create a session between devices A and B
- On B comment out sending confirmation.
- Send some messages from A to B
- On B simulate Olm error.
- Test that all messages are sent again and decrypted successfully.
Reviewers: tomek, marcin
Reviewed By: tomek
Subscribers: ashoat
Differential Revision: https://phab.comm.dev/D13046