Skip to content

[stable-25.0.x] fix(call): restore call audio mode after audio focus interruptions - #6566

Merged
AndyScherzinger merged 1 commit into
stable-25.0.xfrom
backport/6546/stable-25.0.x
Aug 24, 2026
Merged

[stable-25.0.x] fix(call): restore call audio mode after audio focus interruptions#6566
AndyScherzinger merged 1 commit into
stable-25.0.xfrom
backport/6546/stable-25.0.x

Conversation

@backportbot

@backportbot backportbot Bot commented Aug 24, 2026

Copy link
Copy Markdown

Backport of PR #6546

The audio focus change listener in WebRtcAudioManager only logged
changes. A transient focus holder such as the telephony stack switches
the global audio mode and restores its own saved mode on release,
clobbering MODE_IN_COMMUNICATION. After an incoming GSM call the Talk
call therefore continued without hardware echo cancellation and proper
VoIP routing: remote parties heard echo, quiet audio, or nothing until
the call was restarted.

- Re-assert MODE_IN_COMMUNICATION and the selected audio route when
  focus returns after a transient loss (new AudioFocusState tracks this)
- Request focus with AUDIOFOCUS_GAIN via AudioFocusRequest (voice
  communication attributes, delayed gain accepted) instead of the
  deprecated AUDIOFOCUS_GAIN_TRANSIENT hint meant for short use
- Abandon focus via abandonAudioFocusRequest on stop

Fixes #6541

Assisted-by: opencode:ox-alpha
Signed-off-by: Tarek Loubani <tarek@tarek.org>
@backportbot
backportbot Bot requested review from mahibi and tareko August 24, 2026 18:12
@backportbot backportbot Bot added 3. to review Waiting for reviews AI assisted labels Aug 24, 2026
@backportbot backportbot Bot added this to the 25.0.0 milestone Aug 24, 2026
@AndyScherzinger
AndyScherzinger merged commit 94a860a into stable-25.0.x Aug 24, 2026
11 of 15 checks passed
@AndyScherzinger
AndyScherzinger deleted the backport/6546/stable-25.0.x branch August 24, 2026 18:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

3. to review Waiting for reviews AI assisted

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants