Don't wait on live call disconnect for single sim
Remove the logic in CallSequencingControlelr#makeRoomForOutgoingEmergencyCall to wait for the live call to disconnect in the single sim case where we have an active + held call and we're placing an emergency call. It was found that if the two ongoing calls are merging and we send a disconnect, that it's possible for this transaction to timeout and we end up failing to place the emergency call as a result.
Bug: 394977939
Flag: EXEMPT bugfix
Test: atest CtsTelecomCujTestCases
(cherry picked from https://googleplex-android-review.googlesource.com/q/commit:1a4ece76c8cdcfc69ae2b37cd2dda161450f4fb3)
Merged-In: Ie45f68778bbd8b1b199cbb3984aa9ee3666e33e4
Change-Id: Ie45f68778bbd8b1b199cbb3984aa9ee3666e33e4
diff --git a/src/com/android/server/telecom/callsequencing/CallSequencingController.java b/src/com/android/server/telecom/callsequencing/CallSequencingController.java
index f396257..29be3d0 100644
--- a/src/com/android/server/telecom/callsequencing/CallSequencingController.java
+++ b/src/com/android/server/telecom/callsequencing/CallSequencingController.java
@@ -653,8 +653,13 @@
liveCall.setSkipAutoUnhold(true);
// Disconnect the active call instead of the holding call because it is historically
// easier to do, rather than disconnecting a held call and holding the active call.
- return disconnectOngoingCallForEmergencyCall(transactionFuture, liveCall,
+ disconnectOngoingCallForEmergencyCall(transactionFuture, liveCall,
disconnectReason);
+ // Don't wait on the live call disconnect future result above since we're handling
+ // the same phone account case. It's possible that disconnect may time out in the
+ // case that two calls are being merged while the disconnect for the live call is
+ // sent.
+ return transactionFuture;
} else if (heldCall != null) { // Dual sim case
// Note at this point, we should always have a held call then that should
// be disconnected (over the active call) but still enforce with a null check and