mirror of
https://gitlab.linphone.org/BC/public/linphone-android.git
synced 2026-01-17 03:18:06 +00:00
Use Rejected instead of Error call disconnect cause because otherwise it triggers an exception on some devices
This commit is contained in:
parent
679f125870
commit
aad50669c4
1 changed files with 6 additions and 1 deletions
|
|
@ -81,7 +81,12 @@ class TelecomCallControlCallback(
|
|||
} else if (state == Call.State.Error) {
|
||||
scope.launch {
|
||||
Log.w("$TAG Disconnecting call due to error [$message]")
|
||||
callControl.disconnect(DisconnectCause(DisconnectCause.ERROR))
|
||||
try {
|
||||
// For some reason DisconnectCause.ERROR triggers an IllegalArgumentException
|
||||
callControl.disconnect(DisconnectCause(DisconnectCause.REJECTED))
|
||||
} catch (ise: IllegalArgumentException) {
|
||||
Log.e("$TAG Couldn't terminate call control with REJECTED cause: $ise")
|
||||
}
|
||||
}
|
||||
} else if (state == Call.State.Pausing) {
|
||||
scope.launch {
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue