diff options
Diffstat (limited to 'drm/drmserver/DrmManager.cpp')
-rw-r--r-- | drm/drmserver/DrmManager.cpp | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/drm/drmserver/DrmManager.cpp b/drm/drmserver/DrmManager.cpp index 3abf3d3..999295a 100644 --- a/drm/drmserver/DrmManager.cpp +++ b/drm/drmserver/DrmManager.cpp @@ -426,7 +426,9 @@ status_t DrmManager::getAllSupportInfo( return DRM_NO_ERROR; } -DecryptHandle* DrmManager::openDecryptSession(int uniqueId, int fd, off64_t offset, off64_t length) { +DecryptHandle* DrmManager::openDecryptSession( + int uniqueId, int fd, off64_t offset, off64_t length, const char* mime) { + Mutex::Autolock _l(mDecryptLock); status_t result = DRM_ERROR_CANNOT_HANDLE; Vector<String8> plugInIdList = mPlugInManager.getPlugInIdList(); @@ -438,7 +440,7 @@ DecryptHandle* DrmManager::openDecryptSession(int uniqueId, int fd, off64_t offs for (unsigned int index = 0; index < plugInIdList.size(); index++) { String8 plugInId = plugInIdList.itemAt(index); IDrmEngine& rDrmEngine = mPlugInManager.getPlugIn(plugInId); - result = rDrmEngine.openDecryptSession(uniqueId, handle, fd, offset, length); + result = rDrmEngine.openDecryptSession(uniqueId, handle, fd, offset, length, mime); if (DRM_NO_ERROR == result) { ++mDecryptSessionId; @@ -453,7 +455,8 @@ DecryptHandle* DrmManager::openDecryptSession(int uniqueId, int fd, off64_t offs return handle; } -DecryptHandle* DrmManager::openDecryptSession(int uniqueId, const char* uri) { +DecryptHandle* DrmManager::openDecryptSession( + int uniqueId, const char* uri, const char* mime) { Mutex::Autolock _l(mDecryptLock); status_t result = DRM_ERROR_CANNOT_HANDLE; Vector<String8> plugInIdList = mPlugInManager.getPlugInIdList(); @@ -465,7 +468,7 @@ DecryptHandle* DrmManager::openDecryptSession(int uniqueId, const char* uri) { for (unsigned int index = 0; index < plugInIdList.size(); index++) { String8 plugInId = plugInIdList.itemAt(index); IDrmEngine& rDrmEngine = mPlugInManager.getPlugIn(plugInId); - result = rDrmEngine.openDecryptSession(uniqueId, handle, uri); + result = rDrmEngine.openDecryptSession(uniqueId, handle, uri, mime); if (DRM_NO_ERROR == result) { ++mDecryptSessionId; |