Skip to content

Commit

Permalink
[MediaRecorder] Resume WebmMuxer only if not null
Browse files Browse the repository at this point in the history
There are some cases in which the muxer is null, which lead to crashes.

Bug: 954494
Change-Id: I571d54d56c71d7a674054979a441e6645bc5ac3c
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1578614
Reviewed-by: Miguel Casas <mcasas@chromium.org>
Commit-Queue: Guido Urdaneta <guidou@chromium.org>
Cr-Original-Commit-Position: refs/heads/master@{#653191}(cherry picked from commit bb460bf)
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1581684
Reviewed-by: Guido Urdaneta <guidou@chromium.org>
Cr-Commit-Position: refs/branch-heads/3770@{#43}
Cr-Branched-From: a9eee1c-refs/heads/master@{#652427}
  • Loading branch information
Guido Urdaneta committed Apr 24, 2019
1 parent 52f75b8 commit 9555dc9
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion content/renderer/media_recorder/media_recorder_handler.cc
Original file line number Diff line number Diff line change
Expand Up @@ -343,7 +343,8 @@ void MediaRecorderHandler::Resume() {
video_recorder->Resume();
for (const auto& audio_recorder : audio_recorders_)
audio_recorder->Resume();
webm_muxer_->Resume();
if (webm_muxer_)
webm_muxer_->Resume();
}

void MediaRecorderHandler::EncodingInfo(
Expand Down

0 comments on commit 9555dc9

Please sign in to comment.