Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixed some scenarios where an answered call keeps ringing. #1710

Merged
merged 1 commit into from
Feb 3, 2023

Conversation

nimau
Copy link
Contributor

@nimau nimau commented Feb 3, 2023

This PR fixes some scenarios where a call continues to ring, even after being answered (or declined) elsewhere.

Related issues:
element-hq/element-ios#6614

The main issue here is that the expiration timer may be fired after 1 minute for a call that is already ended (because it has been answered elsewhere). In this case, setting its state to ended can pause the MXSession and prevents the current ringing call to receive any further events.

Here is the list of changes made to fix this issue:

  • Invalidate the expiration timer once the call has been answered or declined elsewhere
  • Avoid updating the state of an ended call:

- Avoid updating the state of an ended call
- Invalidate the expiration timer once the call has been answered or declined elsewhere
@nimau nimau force-pushed the nimau/fix-call_keeps_ringing branch from 6a06b90 to 54c717f Compare February 3, 2023 15:12
@nimau nimau added the bug label Feb 3, 2023
@nimau nimau marked this pull request as ready for review February 3, 2023 15:16
@codecov
Copy link

codecov bot commented Feb 3, 2023

Codecov Report

Base: 17.52% // Head: 37.41% // Increases project coverage by +19.88% 🎉

Coverage data is based on head (54c717f) compared to base (fef497b).
Patch coverage: 0.00% of modified lines in pull request are covered.

Additional details and impacted files
@@             Coverage Diff              @@
##           develop    #1710       +/-   ##
============================================
+ Coverage    17.52%   37.41%   +19.88%     
============================================
  Files          612      612               
  Lines        95947    95958       +11     
  Branches     40259    41475     +1216     
============================================
+ Hits         16813    35899    +19086     
+ Misses       78623    59009    -19614     
- Partials       511     1050      +539     
Impacted Files Coverage Δ
MatrixSDK/VoIP/MXCall.m 0.00% <0.00%> (ø)
MatrixSDKTests/MXHTTPAdditionalHeadersUnitTests.m 76.59% <0.00%> (-8.52%) ⬇️
...o/Algorithms/RoomEvent/MXRoomEventDecryption.swift 54.80% <0.00%> (-0.54%) ⬇️
MatrixSDK/Utils/Media/MXMediaManager.m 1.88% <0.00%> (+0.47%) ⬆️
MatrixSDK/Contrib/Swift/MXRestClient.swift 2.22% <0.00%> (+0.74%) ⬆️
...gations/LocationSharing/MXBeaconAggregations.swift 4.44% <0.00%> (+1.26%) ⬆️
MatrixSDKTests/MXBackgroundSyncServiceTests.swift 1.84% <0.00%> (+1.84%) ⬆️
...trixSDK/Crypto/CrossSigning/MXCrossSigningV2.swift 23.12% <0.00%> (+1.87%) ⬆️
MatrixSDK/Contrib/Swift/MXSession.swift 14.38% <0.00%> (+2.05%) ⬆️
MatrixSDK/Crypto/Recovery/MXRecoveryService.m 2.33% <0.00%> (+2.33%) ⬆️
... and 188 more

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

☔ View full report at Codecov.
📢 Do you have feedback about the report comment? Let us know in this issue.

Copy link
Contributor

@aringenbach aringenbach left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@nimau nimau merged commit 922a570 into develop Feb 3, 2023
@nimau nimau deleted the nimau/fix-call_keeps_ringing branch February 3, 2023 16:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants