mirror of
https://github.com/androidx/media.git
synced 2025-05-06 23:20:42 +08:00
Fix NPE in FakeAdaptiveMediaPeriod.
The compositeSequenableLoader was causing NPEs in isLoading. Initializing it upfront prevents this problem and is in line with what we do in all real MediaPeriods. PiperOrigin-RevId: 275491511
This commit is contained in:
parent
694ccf424b
commit
4e667b899d
@ -61,6 +61,7 @@ public class FakeAdaptiveMediaPeriod extends FakeMediaPeriod
|
||||
this.transferListener = transferListener;
|
||||
this.durationUs = durationUs;
|
||||
this.sampleStreams = newSampleStreamArray(0);
|
||||
this.sequenceableLoader = new CompositeSequenceableLoader(new SequenceableLoader[0]);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
Loading…
x
Reference in New Issue
Block a user