Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Skip to content
Commit af572a44 authored by Tyler Gunn's avatar Tyler Gunn
Browse files

Correct issue where quick succession calls both get canceled.

There is logic in makeRoomForOutgoingCall which is supposed to disconnect
a stuck connecting call in favor of a new outgoing call.  However, if the
user makes two outgoing calls in quick succession, both will get
disconnected (one in Telecom, one in Telephony).

We ultimately want the CallAnomalyWatchDog clean up stuck connecting
calls, but it's unfortunately not able to currently detect calls stuck
in connecting state because that includes the new outgoing call broadcast
which can take long.

For now, we'll just track how long a call has been around since it was
created and use that as a proxy for how long its stuck in connecting state.
This way we'll ONLY disconnect calls stuck for > 5 sec when making room
for an outgoing call.

The consequence is that in the case of 2 quick succession outgoing calls
we'll not allow the second one (it'll fail) but we won't cancel the first
one, so we'll at least get one call to succeed.

Fixes: 275324976
Test: Added new unit tests for this case and adjusted existing tests.
Change-Id: I9f9f72c4b72debc2d560eeea122204c4ab516cf1
parent 94990ef8
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment