Skip to content

Commit

Permalink
Fix NPE releasing HlsMediaPeriod
Browse files Browse the repository at this point in the history
Issue: #1907

-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=135798950
  • Loading branch information
ojw28 committed Oct 11, 2016
1 parent 29f3eb5 commit 996fe47
Showing 1 changed file with 4 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -103,8 +103,10 @@ public void run() {
public void release() {
continueLoadingHandler.removeCallbacksAndMessages(null);
manifestFetcher.release();
for (HlsSampleStreamWrapper sampleStreamWrapper : sampleStreamWrappers) {
sampleStreamWrapper.release();
if (sampleStreamWrappers != null) {
for (HlsSampleStreamWrapper sampleStreamWrapper : sampleStreamWrappers) {
sampleStreamWrapper.release();
}
}
}

Expand Down

0 comments on commit 996fe47

Please sign in to comment.