summaryrefslogtreecommitdiffstats
path: root/content/public
diff options
context:
space:
mode:
authorMin Qin <qinmin@chromium.org>2016-01-21 13:41:38 -0800
committerMin Qin <qinmin@chromium.org>2016-01-21 21:45:01 +0000
commite864b52b25f9f002eb63a2f2db0c06854717d6ea (patch)
tree6b0539fa8de727bfb25bf16abaf51fb98b7653b5 /content/public
parentfee5fd62c2251ca6e29e9b92882fd040bec66b25 (diff)
downloadchromium_src-e864b52b25f9f002eb63a2f2db0c06854717d6ea.zip
chromium_src-e864b52b25f9f002eb63a2f2db0c06854717d6ea.tar.gz
chromium_src-e864b52b25f9f002eb63a2f2db0c06854717d6ea.tar.bz2
Merge:Catch runtime exception when creating MediaThrottler
MediaPlayer.create() can throw Runtime exception. Catch the exception to prevent app crash. TBR=yfriedman BUG=579702 Review URL: https://codereview.chromium.org/1611193004 Cr-Commit-Position: refs/heads/master@{#370783} (cherry picked from commit c4a11e8be4fd16ec51ee3a5efcc22e57043b3475) Review URL: https://codereview.chromium.org/1613383002 . Cr-Commit-Position: refs/branch-heads/2623@{#55} Cr-Branched-From: 92d77538a86529ca35f9220bd3cd512cbea1f086-refs/heads/master@{#369907}
Diffstat (limited to 'content/public')
-rw-r--r--content/public/android/java/src/org/chromium/content/browser/MediaThrottler.java2
1 files changed, 2 insertions, 0 deletions
diff --git a/content/public/android/java/src/org/chromium/content/browser/MediaThrottler.java b/content/public/android/java/src/org/chromium/content/browser/MediaThrottler.java
index 9992704..ece07e1 100644
--- a/content/public/android/java/src/org/chromium/content/browser/MediaThrottler.java
+++ b/content/public/android/java/src/org/chromium/content/browser/MediaThrottler.java
@@ -107,6 +107,8 @@ class MediaThrottler implements MediaPlayer.OnErrorListener {
mPlayer = MediaPlayer.create(mContext, R.raw.empty);
} catch (IllegalStateException e) {
Log.e(TAG, "Exception happens while creating the watch dog player.", e);
+ } catch (RuntimeException e) {
+ Log.e(TAG, "Exception happens while creating the watch dog player.", e);
}
if (mPlayer == null) {
Log.e(TAG, "Unable to create watch dog player, treat it as server crash.");