* commit '406dd5d1e48752177753666867403542e1f400ca': Fixed the false drm recognition.
This commit is contained in:
@@ -335,11 +335,13 @@ status_t AwesomePlayer::setDataSource_l(
|
||||
return UNKNOWN_ERROR;
|
||||
}
|
||||
|
||||
dataSource->getDrmInfo(mDecryptHandle, &mDrmManagerClient);
|
||||
if (mDecryptHandle != NULL) {
|
||||
CHECK(mDrmManagerClient);
|
||||
if (RightsStatus::RIGHTS_VALID != mDecryptHandle->status) {
|
||||
notifyListener_l(MEDIA_ERROR, MEDIA_ERROR_UNKNOWN, ERROR_DRM_NO_LICENSE);
|
||||
if (extractor->getDrmFlag()) {
|
||||
dataSource->getDrmInfo(mDecryptHandle, &mDrmManagerClient);
|
||||
if (mDecryptHandle != NULL) {
|
||||
CHECK(mDrmManagerClient);
|
||||
if (RightsStatus::RIGHTS_VALID != mDecryptHandle->status) {
|
||||
notifyListener_l(MEDIA_ERROR, MEDIA_ERROR_UNKNOWN, ERROR_DRM_NO_LICENSE);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -2113,12 +2115,14 @@ status_t AwesomePlayer::finishSetDataSource_l() {
|
||||
}
|
||||
}
|
||||
|
||||
dataSource->getDrmInfo(mDecryptHandle, &mDrmManagerClient);
|
||||
if (extractor->getDrmFlag()) {
|
||||
dataSource->getDrmInfo(mDecryptHandle, &mDrmManagerClient);
|
||||
|
||||
if (mDecryptHandle != NULL) {
|
||||
CHECK(mDrmManagerClient);
|
||||
if (RightsStatus::RIGHTS_VALID != mDecryptHandle->status) {
|
||||
notifyListener_l(MEDIA_ERROR, MEDIA_ERROR_UNKNOWN, ERROR_DRM_NO_LICENSE);
|
||||
if (mDecryptHandle != NULL) {
|
||||
CHECK(mDrmManagerClient);
|
||||
if (RightsStatus::RIGHTS_VALID != mDecryptHandle->status) {
|
||||
notifyListener_l(MEDIA_ERROR, MEDIA_ERROR_UNKNOWN, ERROR_DRM_NO_LICENSE);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -114,6 +114,9 @@ sp<MediaExtractor> MediaExtractor::Create(
|
||||
ret = new AVIExtractor(source);
|
||||
} else if (!strcasecmp(mime, MEDIA_MIMETYPE_CONTAINER_WVM)) {
|
||||
ret = new WVMExtractor(source);
|
||||
if (ret != NULL) {
|
||||
isDrm = true;
|
||||
}
|
||||
} else if (!strcasecmp(mime, MEDIA_MIMETYPE_AUDIO_AAC_ADTS)) {
|
||||
ret = new AACExtractor(source, meta);
|
||||
} else if (!strcasecmp(mime, MEDIA_MIMETYPE_CONTAINER_MPEG2PS)) {
|
||||
|
||||
Reference in New Issue
Block a user