summaryrefslogtreecommitdiffstats
path: root/media/jni
diff options
context:
space:
mode:
authorRonghua Wu <ronghuawu@google.com>2015-04-30 15:40:35 +0000
committerAndroid (Google) Code Review <android-gerrit@google.com>2015-04-30 15:40:36 +0000
commit1b12db9e6225171da87ed9586daeabf76b53c05a (patch)
tree85a48ff1d5ca9ad923a00cfc3e4d924a8c636a88 /media/jni
parent5793f22e68f74522dfe5780b96b22d18617467be (diff)
parentfb621e8737392ef10acbba083b46aedf6583c9a4 (diff)
downloadframeworks_base-1b12db9e6225171da87ed9586daeabf76b53c05a.zip
frameworks_base-1b12db9e6225171da87ed9586daeabf76b53c05a.tar.gz
frameworks_base-1b12db9e6225171da87ed9586daeabf76b53c05a.tar.bz2
Merge "media: set codec exception reason." into mnc-dev
Diffstat (limited to 'media/jni')
-rw-r--r--media/jni/android_media_MediaCodec.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/media/jni/android_media_MediaCodec.cpp b/media/jni/android_media_MediaCodec.cpp
index 5f586a9..e34f9ed 100644
--- a/media/jni/android_media_MediaCodec.cpp
+++ b/media/jni/android_media_MediaCodec.cpp
@@ -592,8 +592,8 @@ static jthrowable createCodecException(
break;
}
- // TODO: propagate reason from MediaCodec.
- int reason = gExceptionReason.reasonHardware;
+ int reason =
+ (err == DEAD_OBJECT) ? gExceptionReason.reasonReclaimed : gExceptionReason.reasonHardware;
return (jthrowable)env->NewObject(clazz.get(), ctor, err, actionCode, msgObj.get(), reason);
}