Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(914)

Unified Diff: webkit/media/android/media_source_delegate.cc

Issue 15927003: Fix MediaPlayerDelegate error handling so it passes the webkitmediasource-errors.html LayoutTest. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase Created 7 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | webkit/media/android/webmediaplayer_android.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webkit/media/android/media_source_delegate.cc
diff --git a/webkit/media/android/media_source_delegate.cc b/webkit/media/android/media_source_delegate.cc
index 03dac325e543990f07c1b8e88a9cf1dcf2f449b6..1b63ed1da9f571c2629067b3abc3d2a0d1afa025 100644
--- a/webkit/media/android/media_source_delegate.cc
+++ b/webkit/media/android/media_source_delegate.cc
@@ -373,14 +373,8 @@ void MediaSourceDelegate::OnDemuxerError(
media::PipelineStatus status) {
DVLOG(1) << "MediaSourceDelegate::OnDemuxerError(" << status << ") : "
<< player_id_;
- if (status != media::PIPELINE_OK) {
- DCHECK(status == media::DEMUXER_ERROR_COULD_NOT_OPEN ||
- status == media::DEMUXER_ERROR_COULD_NOT_PARSE ||
- status == media::DEMUXER_ERROR_NO_SUPPORTED_STREAMS)
- << "Unexpected error from demuxer: " << static_cast<int>(status);
- if (!update_network_state_cb_.is_null())
- update_network_state_cb_.Run(WebMediaPlayer::NetworkStateFormatError);
- }
+ if (status != media::PIPELINE_OK && !update_network_state_cb_.is_null())
+ update_network_state_cb_.Run(PipelineErrorToNetworkState(status));
}
void MediaSourceDelegate::OnDemuxerInitDone(
« no previous file with comments | « no previous file | webkit/media/android/webmediaplayer_android.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698