Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

StreamVolumeManager crash during Initialization on certain devices when getting getStreamVolume from AudioManager #8191

Closed
saurabhkpatel opened this issue Nov 9, 2020 · 4 comments
Assignees

Comments

@saurabhkpatel
Copy link

[REQUIRED] Issue description

Getting the following crash after bumping the new release version which has this commit: 160ee9d

Crash is:

  • During SimpleExoPlayer inits, StreamVolumeManager sets the volume which gets the streaming volume from AudioManager and it gives NPE.

[REQUIRED] Reproduction steps

This crash is very device-specific, I see this crash only happens on some manufactured (so far only two: RealMe
OPPO) Android 10 devices.

[REQUIRED] Link to test content

NA

[REQUIRED] A full bug report captured from the device

--- Caused by.java.lang.NullPointerException:Attempt to invoke interface method 'java.util.Iterator java.util.List.iterator()' on a null object reference
android.os.createException ( Parcel .java :2093)
android.os.readException ( Parcel .java :2055)
android.os.readException ( Parcel .java :2003)
android.media.getStreamVolume ( IAudioService .java :2409)
android.media.getStreamVolume ( AudioManager .java :1115)
com.google.android.exoplayer2.getVolumeFromManager ( StreamVolumeManager .java :180)
com.google.android.exoplayer2.<init> ( StreamVolumeManager .java :68)
com.google.android.exoplayer2.<init> ( SimpleExoPlayer .java :648)
com.google.android.exoplayer2.build ( SimpleExoPlayer .java :513)

[REQUIRED] Version of ExoPlayer being used

2.12.1

[REQUIRED] Device(s) and version(s) of Android being used

Brand: realme
Model: realme X2Pro, realMe 5 pro,realme 2 Pro
Brand: OPPO
Model: R15 Pro, A52, A72, K3,

@saurabhkpatel saurabhkpatel changed the title StreamVolumeManager crash on certain devices when getting getStreamVolume from AudioManager StreamVolumeManager crash during Initialization on certain devices when getting getStreamVolume from AudioManager Nov 9, 2020
@kim-vde
Copy link
Contributor

kim-vde commented Nov 10, 2020

This seems to be a device-specific issue in Android framework. I will implement a workaround.

@kim-vde kim-vde self-assigned this Nov 10, 2020
kim-vde added a commit that referenced this issue Nov 11, 2020
#minor-release
Issue:#8191
PiperOrigin-RevId: 341632732
@kim-vde
Copy link
Contributor

kim-vde commented Nov 11, 2020

I just pushed the fix. Please let us know if you still encounter issues with the AudioManager in the future.

@kim-vde kim-vde closed this as completed Nov 11, 2020
@saurabhkpatel
Copy link
Author

@kim-vde : what's the timeline to release this?

@kim-vde
Copy link
Contributor

kim-vde commented Nov 12, 2020

Probably end of November or beginning of December.

icbaker pushed a commit that referenced this issue Nov 30, 2020
@google google locked and limited conversation to collaborators Jan 11, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

2 participants