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

Fix re-joining a call #1752

Merged
merged 1 commit into from
Aug 11, 2024
Merged

Fix re-joining a call #1752

merged 1 commit into from
Aug 11, 2024

Conversation

SystemKeeper
Copy link
Collaborator

@SystemKeeper SystemKeeper commented Aug 10, 2024

The problem is that we reset the currentRoom when we forceReconnect, which is fine for "normal" forced reconnects:

- (void)forceReconnect
{
dispatch_async(dispatch_get_main_queue(), ^{
self->_resumeId = nil;
self->_currentRoom = nil;
[self reconnect];
});
}

In case our publisher peer fails, we want to rejoin the call, for that, we call forceReconnect on NCExternalSignalingController from NCCallController:

if (self->_externalSignalingController) {
[self->_externalSignalingController forceReconnect];
} else {

But for the re-join to work correctly, the NCExternalSignalingController needs to be aware, that we were in a room already:

// Re-join if user was in a room
if (_currentRoom && _sessionChanged) {
[self.delegate externalSignalingControllerWillRejoinCall:self];
[[NCRoomsManager sharedInstance] rejoinRoom:_currentRoom];
}

And this check failed since we reseted currentRoom on a forceReconnect. This results in showing the waiting message "Connecting to the call …" but nothing is ever happening.

How to test

  • Establish a call between ios and web
  • Hit "Pause" on the Xcode debugger
  • Wait until the ios peer is closed/removed from the web
  • Continue execution on Xcode

Signed-off-by: Marcel Müller <[email protected]>
@SystemKeeper SystemKeeper merged commit a6fae97 into master Aug 11, 2024
10 checks passed
@SystemKeeper SystemKeeper deleted the fix-rejoining-call branch August 11, 2024 10:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant