Skip to content

AudioTrack write failed: -6 #627

@lyswhut

Description

@lyswhut

Version

ExoPlayer 2.18.2-2.19.1

More version details

2.18.0 Unknown

Working in 2.17.1 and before

Devices that reproduce the issue

OnePlus ColorOS 13.1, Android 13

Devices that do not reproduce the issue

Xiaomi 12, Android 13

Reproducible in the demo app?

No

Reproduction steps

This error will receive any online MP3 file, but if you run the "screen record" app, the player will work normally

Expected result

The media plays successfully

Actual result

09-01 10:27:47.948  4743  6553 D Avrcp_ext: isMusicActive = false mAudioPlaybackIsActive = true player state = PlaybackState {state=0, position=0, buffered position=0, speed=1.0, updated=978806, actions=311, custom actions=[], active item id=-1, error=null}
09-01 10:27:47.949  4743  4743 D OplusBluetoothAudioGuard: AudioManager Player in started state: cn.toside.music.mobile
09-01 10:27:47.949  4743  4743 D OplusBluetoothAudioGuard: AudioManager Active Player: cn.toside.music.mobile
09-01 10:27:47.949  4743  4743 D OplusBluetoothAudioGuard: send MESSAGE_MEDIA_STATE_CHANGE_CHECK
09-01 10:27:47.949  8829 10308 D MIDASApplication: MIDASHandler: switch message
09-01 10:27:47.949  9818 11079 E AudioTrack-JNI: Error -32 during AudioTrack native read
09-01 10:27:47.949  9818 11079 E MediaCodecAudioRenderer: Audio sink error
09-01 10:27:47.949  9818 11079 E MediaCodecAudioRenderer:   k5.x$e: AudioTrack write failed: -6
09-01 10:27:47.949  9818 11079 E MediaCodecAudioRenderer:       at k5.m0.q0(Unknown Source:175)
09-01 10:27:47.949  9818 11079 E MediaCodecAudioRenderer:       at k5.m0.d0(Unknown Source:24)
09-01 10:27:47.949  9818 11079 E MediaCodecAudioRenderer:       at k5.m0.u(Unknown Source:371)
09-01 10:27:47.949  9818 11079 E MediaCodecAudioRenderer:       at k5.w0.R0(Unknown Source:45)
09-01 10:27:47.949  9818 11079 E MediaCodecAudioRenderer:       at a6.t.Q(Unknown Source:62)
09-01 10:27:47.949  9818 11079 E MediaCodecAudioRenderer:       at a6.t.p(Unknown Source:47)
09-01 10:27:47.949  9818 11079 E MediaCodecAudioRenderer:       at i5.n1.n(Unknown Source:97)
09-01 10:27:47.949  9818 11079 E MediaCodecAudioRenderer:       at i5.n1.handleMessage(Unknown Source:220)
09-01 10:27:47.949  9818 11079 E MediaCodecAudioRenderer:       at android.os.Handler.dispatchMessage(Handler.java:102)
09-01 10:27:47.949  9818 11079 E MediaCodecAudioRenderer:       at android.os.Looper.loopOnce(Looper.java:240)
09-01 10:27:47.949  9818 11079 E MediaCodecAudioRenderer:       at android.os.Looper.loop(Looper.java:351)
09-01 10:27:47.949  9818 11079 E MediaCodecAudioRenderer:       at android.os.HandlerThread.run(HandlerThread.java:67)
09-01 10:27:47.950  4743  6774 I OplusBtAudioRouteMonitor: updateAudioPlaybackList() isMusicActive: true, virtualCallActive: false
09-01 10:27:47.950  4743  6774 D OplusBtAudioRouteMonitor: handleAudioPlaybackConfigsChanged() virtual call: false->false, music play: false->true
09-01 10:27:47.950  4743  6774 D OplusBtAudioRouteMonitor: handleAudioPlaybackConfigsChanged() a2dp record: false, a2dp state: 0, sco record: false, sco state: 0
09-01 10:27:47.950  4743  6774 D OplusBtAudioRouteMonitor: clearDiedAudioPlayerbackList()
09-01 10:27:47.951  9818 11079 W ExoPlayerImplInternal: Recoverable renderer error
09-01 10:27:47.951  9818 11079 W ExoPlayerImplInternal:   i5.t: MediaCodecAudioRenderer error, index=1, format=Format(null, null, null, audio/mpeg, null, -1, null, [-1, -1, -1.0], [2, 44100]), format_supported=YES
09-01 10:27:47.951  9818 11079 W ExoPlayerImplInternal:       at i5.n1.handleMessage(Unknown Source:346)
09-01 10:27:47.951  9818 11079 W ExoPlayerImplInternal:       at android.os.Handler.dispatchMessage(Handler.java:102)
09-01 10:27:47.951  9818 11079 W ExoPlayerImplInternal:       at android.os.Looper.loopOnce(Looper.java:240)
09-01 10:27:47.951  9818 11079 W ExoPlayerImplInternal:       at android.os.Looper.loop(Looper.java:351)
09-01 10:27:47.951  9818 11079 W ExoPlayerImplInternal:       at android.os.HandlerThread.run(HandlerThread.java:67)
09-01 10:27:47.951  9818 11079 W ExoPlayerImplInternal:   Caused by: k5.x$e: AudioTrack write failed: -6
09-01 10:27:47.951  9818 11079 W ExoPlayerImplInternal:       at k5.m0.q0(Unknown Source:175)
09-01 10:27:47.951  9818 11079 W ExoPlayerImplInternal:       at k5.m0.d0(Unknown Source:24)
09-01 10:27:47.951  9818 11079 W ExoPlayerImplInternal:       at k5.m0.u(Unknown Source:371)
09-01 10:27:47.951  9818 11079 W ExoPlayerImplInternal:       at k5.w0.R0(Unknown Source:45)
09-01 10:27:47.951  9818 11079 W ExoPlayerImplInternal:       at a6.t.Q(Unknown Source:62)
09-01 10:27:47.951  9818 11079 W ExoPlayerImplInternal:       at a6.t.p(Unknown Source:47)
09-01 10:27:47.951  9818 11079 W ExoPlayerImplInternal:       at i5.n1.n(Unknown Source:97)
09-01 10:27:47.951  9818 11079 W ExoPlayerImplInternal:       at i5.n1.handleMessage(Unknown Source:220)
09-01 10:27:47.951  9818 11079 W ExoPlayerImplInternal:       ... 4 more

Media

Not applicable

Bug Report

  • You will email the zip file produced by adb bugreport to [email protected] after filing this issue.

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions